|
dev
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
Formatting a string with leading zeroes.If I have a number representing a number of minutes and I want to format it
as a string with two characters, with a leading 0 if the value is less than 10, how do I do that? Many thanks. Andrew,
>If I have a number representing a number of minutes and I want to format it number.ToString("00")>as a string with two characters, with a leading 0 if the value is less than >10, how do I do that? Mattias -- Mattias Sjögren [C# MVP] mattias @ mvps.org http://www.msjogren.net/dotnet/ | http://www.dotnetinterop.com Please reply only to the newsgroup. Thanks, to Mattias as well. I will try that.
- A Show quote "Syed Abbas Naqvi" <abbas.***@gmail.com> wrote in message news:1138336611.183293.115530@z14g2000cwz.googlegroups.com... > Try this out. > strNumber = Format(yourNumber,"00") > |
|||||||||||||||||||||||