Imports System.IO
Module Module1
Sub Main()
Dim list As New List(Of String)
Using sr As StreamReader = New StreamReader("d:\\file.txt")
Dim line As String
line = sr.ReadLine
Do While (Not line Is Nothing)
list.Add(line)
Console.WriteLine(line)
line = sr.ReadLine
Loop
End Using
End Sub
' run:
'
'VB.NET Programming language
'in the .NET
'Framework
End Module