Dim TextFile As String = "C:\correo\contact.txt"
Dim separator = "*********************************"
If Not File.Exists(TextFile) Then
Dim fs As New FileStream(TextFile, FileMode.Create, FileAccess.Write, FileShare.ReadWrite)
fs.Close()
End If
Dim swText As New StreamWriter(File.OpenWrite(TextFile), System.Text.Encoding.UTF8)
swText.BaseStream.Seek(0, SeekOrigin.End)
swText.WriteLine("fecha: " + Me.fecha.Text)
swText.WriteLine("nombre: " + Me.txt_nombre.Text)
swText.WriteLine("empresa: " + Me.txt_empresa.Text)
swText.WriteLine("e-mail: " + Me.txt_email.Text)
swText.WriteLine("telefono: " + Me.txt_telef.Text)
swText.WriteLine("ciudad: " + Me.txt_ciudad.Text)
swText.WriteLine("asunto: " + Me.txt_asunto.Text)
swText.WriteLine("Comentario: " + Me.txt_coment.Text)
sw.WriteLine(Chr(10) + Chr(13) + separator + Chr(10) + Chr(13))
sw.Flush() 'liberamos y cerramos objetos
sw.Close()