SAP Knowledge Base Article - Public

2384367 - How to create custom number format in Crystal Reports

Symptom

  • The number is shown like 111,111,111.11 by default and it needs to be changed to a specific format (for example to indian format: 11,11,11,111.11)

Environment

  • SAP Crystal Reports 20xx

Reproducing the Issue

  1. Create a report against e-fashion universe in the Crystal Reports Designer
  2. Insert the field "Sales Revenue"
  3. Go to format settings
  4. Observe that there's no option to mask the format to something like ##,##,##,###.##

Resolution

  1. Create a new formula
  2. Use the function: cstr ({eFashion_query.Sales revenue}, "##,##,##,###.##")
    CustomFormat.jpg
  3. The result will be a string field with the expected format
    CustomFormat2.jpg
  4. If you want to make calculations (aggregation, average etc.) use the original field, and the formula for creating a visible field with the custom format in the end

Keywords

currency, date, number, format, change, mask, make, generate, formula, CRD, CR, designer, 2016, 2013, 2011, 2008 , KBA , BI-RA-CR , Crystal Reports designer or Business View Manager , Problem

Product

SAP Crystal Reports 2011 ; SAP Crystal Reports 2013 ; SAP Crystal Reports 2016