Use a StringWriter to write into a string : StringWriter « File Directory « VB.Net






Use a StringWriter to write into a string

Use a StringWriter to write into a string
 
Imports System
Imports System.IO
Imports System.Text


Public Class MainClass

   Shared Sub Main()
        ' Use a StringWriter to write into a string.
        Dim string_writer As New StringWriter()
        string_writer.WriteLine("www.java2s.com")
        string_writer.WriteLine("www.java2s.com")
        Console.WriteLine(string_writer.ToString)

   End Sub 

End Class

           
         
  








Related examples in the same category

1.Create StringWriter class with the specified format control.
2.Create StringWriter class that writes to the specified StringBuilder.
3.Create StringWriter class.