It depends...
If you simply want to throw a carriage-return linefeed into a string for
display, simply use the \n code. For example:
string strTest = "This is the First Line.\nThis is the Second Line."
If you're writing to a file, you may find the NewLine property of the
TextWriter convenient.
- Carl
"Lauchlan M" <LM********@Hotmail.com> wrote in message
news:eY**************@TK2MSFTNGP11.phx.gbl...
How do I add a linefeed (ASCII character 10) to a string?
For example in Delphi I would do
TheString := PreString+ Chr(10) + PostString;
Where Chr(10) whacks in the ascii character for line feed / carriage
return and prestring and poststring are other strings.
How do I do this in C#?
Thanks!
Lauchlan M