C# StreamReader class is used to read string from the stream. It inherits TextReader class. It provides Read() and ReadLine() methods to read data from the stream.
C# StreamReader example to read one line
Let's see the simple example of StreamReader class that reads a single line of data from the file.
C# StreamReader example to read all lines
Hello C# this is file handling