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 wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Preceding Zero Formula for Crystal Report

Status
Not open for further replies.

goldmine925

Instructor
Oct 18, 2007
1
US
I have a field in report that is supposed to be 10 characters long but most of the values for this field do not meet length. I need to know how to add the preceding zeros to all the fields so the length matches in the report. Any suggestions would be greatly appreciated!
 
What is the datatype of the field, string or numeric?

If it is string, then try this:

right("0000000000" & {table.field},10)

if it is a number, then try this:

totext({table.field},"0000000000")

~Brian
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top