• How to read a text file one line at a time in ASP.NET

    by  • June 14, 2013 • Microsoft .NET C# (C-Sharp), Microsoft ASP.NET, Microsoft VB.NET • 0 Comments

    This is a series of articles about reading text files and the first article is about to read text file one line at a time. You can use ReadLine() method of StreamReader class to read line by line from a text file. StreamReader class actually has four methods to read text files. I will explain all of the four methods in my articles.

    ReadLine() Method

    ReadLine() method reads a line of characters from the current stream and returns a string. So it reads the data line by line. Let’s see how we can use this method.

    Read text file line by line in C#

    Read text file line by line in VB.NET

    Avatar of GetCodeSnippet.com


    GetCodeSnippet.com provides you high quality Microsoft .NET development related articles, tutorials and sample code for ASP.NET, C#, VB.NET, AJAX, WCF, WPF, Web Services, Windows Services, SQL Server and other technologies.

    Leave a Reply