Imports System.IO
public class Test
public Shared Sub Main
Dim file_name As String = "test.txt"
Dim stream_writer As New StreamWriter(file_name)
stream_writer.Write("The quick brown fox")
stream_writer.WriteLine(" jumps over the lazy dog.")
stream_writer.Close()
Dim stream_reader As New StreamReader(file_name)
Console.WriteLine(stream_reader.ReadToEnd())
stream_reader.Close()
End Sub
End class
|