In C# I have an integer value which need to be convereted to string but it needs to add zeros before:
For Example:
int i = 1;
When
.NET has an easy function to do that in the String class. Just use:
String
.ToString().PadLeft(4, '0') // that will fill your number with 0 on the left, up to 4 length int i = 1; i.toString().PadLeft(4,'0') // will return "0001"