Environment constants

benPearce picture benPearce · Nov 17, 2008 · Viewed 11.8k times · Source

Is there an equivalant to Environment.NewLine in DotNet for a Tab character?

Answer

Christian C. Salvadó picture Christian C. Salvadó · Nov 17, 2008

NewLine is on the Environment class because the new line specification varies between platforms:

It's "\r\n" for non-Unix platforms and "\n" for Unix platforms. However tab is always "\t".