I think that I don't understant ToString()
method correctly. How to get number on 3 digits?
12 as 012
123 as 123
6 as 006
i.ToString("000");
results in 6 as 600.
I think that I don't understant ToString()
method correctly. How to get number on 3 digits?
12 as 012
123 as 123
6 as 006
i.ToString("000");
results in 6 as 600.
i.PadLeft(3,'0');
More info on PadLeft
https://msdn.microsoft.com/en-us/library/92h5dc07(v=vs.110).aspx