Q: What is File Mode? Types Of file mode? What is Pointer? Which one is most useful in
Structure or Union?
Answer:The meaning of file mode means in which mode we want to open the file.types of modesare read mode,write mode.pointer is the variable which holds the address of another variable.union r useful bcoz of memory no wastage but structures are frequently used than unions.
contributed by : Saravana Kumar
Reference:
http://www.coolinterview.com/type.asp?iType=701
http://jspservlettutorial.info/latest-id-104-tid-525-C-Interview-Questions-and-
Answers.html
contributed by : Majesh.S
Q. About System.IO Name Space
Answer. The classes in the namespace System.IO provides various methods to retrieve
and changes information about Files as well as Directories . In C#, to perform a file I/O
operation, you can use the same familiar basics of creating, opening, closing, reading, and
writing using .NET Framework equivalent classes and methods.
contributed by: Majesh.S
Q. How to use C# Directory Class
Answer: Directory class in CSharp exposes methods to create , delete , move etc. operations
to directories and subdirectories . Because of the static nature of C# Directory class , we
do not have to instantiate the class. We can call the methods in the C# Directory class
directly from the Directory class itself.
contributed by : Majesh.S
Q. How to use C# FileStream Class
Answer: The FileStream Class represents a File in the Computer. Use the FileStream class to
read from, write to, open, and close files on a file system, as well as to manipulate other
file related operating system handles including pipes, standard input, and standard output.
FileStream allows to move data to and from the stream as arrays of bytes. We operate
File using FileMode in FileStream Class.
contributed by : Majesh.S
Q. How to use C# Textreader Class
Answer: Textreader and TextWriter are the another way to read and write file respectively,
even though these are not stream classes. Textreader represents a reader that can read a sequential
series of characters. The StreamReader and StreamWriter classes are derived from
TextReader and TextWriter classes respectively, which read characters from streams and strings.
.
click to go to index page of .net questions
No comments:
Post a Comment