Crystal Reports – How to convert number to text without formatting (no commas and decimal)

The following code shows how to convert a number to text in a Crystal Reports formula – whilst also removing all formatting.

For example, the number 1000 in your data source would by default appear in Crystal Reports as 1,000.00

This code show how to use toText to display the number as 1000

This is useful if the number is some sort of ID or code.

 

toText( {DataSource.Number}, 0, "" )

Note – this should only be used where you need to display the number as part of a string – e.g. “Reference: ” + Number

If you simply want to control the formatting of the number see Crystal Reports – How to format number fields

 

Reference: http://www.forumtopics.com/busobj/viewtopic.php?t=41836