I am running into an issue formatting a javascript number. What is the equivalent of this csharp code in javascript:
var cSharpNumber = 10000;
string formattedNumber = cSharpNumber.ToString("#,###"); //this should show 10,000
I would like to avoid having to bring in other plugins if possible
JavaScript doesn’t provide any way to do this out of the box, so you will have to use some custom code. A quick google search turned up this, which looks good to me:
http://www.mredkj.com/javascript/nfbasic.html