Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Rexx and Leading Zero's 1

Status
Not open for further replies.

CDMZZZ

Technical User
Jan 30, 2008
4
GB
Hi,

I am writing out a number to a file that has a leading Zero
eg. 01,02,03 etc only the leading zero is being dropped so I get 1,2,3 which is not what I require.

Whats if any code can I put in to preserve the Zero's



 
try x = right(iValue,13,'0')

where iValue = your variable
13 = is the final length of the number you want

Regards

Barry
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top