Currently in my application I have an increment logic as below, and it fails now when b
value above 9
(i.e 00010
, 00011
). As the limit is 4 digits which should become 0010
, 0011
and so on.
How can i make value to 0010
instead of 00010
var b = 0;
for (var p = 0; p < tabarray.length; p++)
{
b = b + 1;
tabarray[p].ItemKey = "000" + b;
}