integer variable will not consider Leading zeroes
so that
if you will assign
01234 to integer variable it will automatically save it in
x
variable as
1234
so, add leading zeros after converting x to string
string myString = String.Format("{0:00000}",x)
Happy coding!
:)