Seibar Seibar - 1 year ago 88
C# Question

.NET String.Format() to add commas in thousands place for a number

I want to add a comma in the thousands place for a number.


Answer Source
String.Format("{0:n}", 1234);

string.Format("{0:n0}", 9876); // no digits after the decimal point.
Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download