How to use Format function to format a string.
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-14-2010
01:01 AM
04-14-2010
01:01 AM
How to use Format function to format a string.
I have an string variable that increments in the script everytime the script runs. ex: variable with value 02. Tried to Format this in the form of "0000" using aqstring.Format("0000", Variablestring). I am not able to. Can you pleasetell me if there is a solution. I tried the format specifics under the format expression with the help. but could not.
3 REPLIES 3
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-15-2010
05:22 AM
04-15-2010
05:22 AM
I have string variable with value "2". i want to fomat it to "0002". I used aqstring.format("0000", my string variable with vale :"2").
I am not able to. can any one suggest.
I am not able to. can any one suggest.
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-15-2010
09:44 AM
04-15-2010
09:44 AM
numericString = "2"
formattedString = aqString.Format("%04i", aqConvert.StrToInt(numericString))
formattedString = aqString.Format("%04i", aqConvert.StrToInt(numericString))
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-19-2010
07:34 AM
04-19-2010
07:34 AM
Thankyou very much, that worked.
