Reading text file using streamreader;

Imports System.IO

 

 

  Dim list As New List(Of String)

        ' Open file.txt with the Using statement.

        Using r As StreamReader = New StreamReader("file.txt")

            ' Store contents in this String.

            Dim line As String

 

        [...]