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!

Padding number with leading zero?

Status
Not open for further replies.

WhiteKnight2K

Technical User
Dec 30, 2002
26
0
0
CA
Hello, quick question, is it possible to "pad" a number field with a leading zero in CR? The number I pull from the database does not have a leading zero for years < 10. I have a parameter field which allows the user to select records based on the Year field corresponding to that record. However the Year field is just a number and does not save a leading zero for years < 10 in the database. Therefore, I need to display the year entered by the user on the report, but for years < 10 the leading zero does not show, even if the user enters it in the parameter dialog box.

Thanks!
 
You could create a formula to display the parameter value:

totext({?numberparameter},"00")

-LB
 
You are a genius lbass...I never knew of that function. Thanks again as always!!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top