how can I format text using WriteAllText method?

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

hello,
I'm trying to write a some text to a text file using WriteAllText method.
This method works fine but I don't understand how can I use format specifiers
to format the text as we use in C i.e "\n" for newline, "\t" for tab,...etc.
bye
 
johnabraham101 said:
hello,
I'm trying to write a some text to a text file using WriteAllText
method. This method works fine but I don't understand how can I use
format specifiers to format the text as we use in C i.e "\n" for
newline, "\t" for tab,...etc. bye


See constants: vbCr, vbLf, vbCrLf, vbTab



Armin
 
johnabraham101 said:
I'm trying to write a some text to a text file using WriteAllText method.
This method works fine but I don't understand how can I use format
specifiers
to format the text as we use in C i.e "\n" for newline, "\t" for
tab,...etc.

s = _
"Hello" & ControlChars.Tab & "World" & ControlChars.NewLine _
"Second Line"
///

Note that the compiler will emit a single string literal to the assembly's
IL. No concatenation needs to be performed at runtime if all parts are
constant.
 
Back
Top