Imports System
Imports System.Management
Imports System.Diagnostics
Public Class Sample
Public Shared Sub Main()
Dim myWriter As New TextWriterTraceListener()
myWriter.Writer = System.Console.Out
Trace.Listeners.Add(myWriter)
myWriter.Write("this ")
myWriter.WriteLine(" is a test.")
' Flush and close the output.
myWriter.Flush()
myWriter.Close()
End Sub
End Class