Home > Uncategorized > Rounding when Exporting to Excel

Rounding when Exporting to Excel

When you use the rounding feature in Crystal Reports you generally do so, as follows:
(Right Click on the Field > Format Field > Number > Customize)
rounding

You can select the number of decimal places to which you wish to Display in the Report.

However, When you export this to excel you will still get the full Value.

For example. If the Value was 56.76999999
And you have select to round to 2 Decimal places.
The Report will display 56.77

However when you export, the field will be 56.76999999

If you would rather have the export to excel match the report.

Simply add a formula which performs the rounding.

Round({Table1.Fieldname1},2)

This will mean when you export. The Excel Field will match the Value Displayed in the Report.

 

Categories: Uncategorized
  1. No comments yet.
  1. No trackbacks yet.

Leave a comment