Technical Questions
 Crystal Reports Forum : Crystal Reports 9 through 2022 : Technical Questions
Message Icon Topic: Formatting Numbers Post Reply Post New Topic
Author Message
jgarner
Senior Member
Senior Member


Joined: 23 Jan 2009
Location: United States
Online Status: Offline
Posts: 159
Quote jgarner Replybullet Topic: Formatting Numbers
     Posted: 06 Nov 2009 at 7:20am

Is there a way to show a number with this format: 01 or 001? When I display a field such as the ‘Record Number’,  it only shows up as 1. Thanks for your help.

IP IP Logged
DBlank
Moderator
Moderator


Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
Quote DBlank Replybullet Posted: 06 Nov 2009 at 7:55am
you can change it to text and mask it with zeros, the red zeros would give you the total number of characters to use so in my example 1=001, 12=012 and 123=123:
totext({field},'000')
IP IP Logged
jgarner
Senior Member
Senior Member


Joined: 23 Jan 2009
Location: United States
Online Status: Offline
Posts: 159
Quote jgarner Replybullet Posted: 06 Nov 2009 at 8:11am
Thanks DBlank, but unfortunately, I wasn't very specific in my post. The example you posted would be great to use, but the 'Special Fields' - Record Number I'm using from the 'Field Explorer' doesn't show up as a Report Field in the Formula Worshop.
I did try to type in a couple of different field names for the Record Number, but it keeps saying the field doesn't exist.
IP IP Logged
DBlank
Moderator
Moderator


Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
Quote DBlank Replybullet Posted: 06 Nov 2009 at 8:19am

if you just want to increment your rows by one then create a Running Total and use it instead:

totext({#RTotal0},'000')


Edited by DBlank - 06 Nov 2009 at 8:19am
IP IP Logged
jgarner
Senior Member
Senior Member


Joined: 23 Jan 2009
Location: United States
Online Status: Offline
Posts: 159
Quote jgarner Replybullet Posted: 06 Nov 2009 at 8:29am
Yes, Thats exactly what I needed. Thanks.
IP IP Logged
Printable version Printable version

Forum Jump
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot delete your posts in this forum
You cannot edit your posts in this forum
You cannot create polls in this forum
You cannot vote in polls in this forum