How can I create a string with a line feed character in it without adding a carriage return?
Using the Environment.NewLine method on a windows machine returns a CR/LF combo. I need just the LF.
I know about the VBLF in Microsoft.VisualBasic library, but as a company policy we are not allowed to use it.
I would recommend using the constants in the
ControlCharsclass to get the individual LF character. Also, I would recommend using the string builder: