cancel
Showing results for 
Search instead for 
Did you mean: 

Rounding in Crystal Reports

cothmer
Participant
0 Kudos

I have a formula that seems to work but the percentage seems to round up. Is there a way for the field to display 84.62% instead of 85% ? This is what the formula looks like. Thanks.

// calculate the percent of administrations that were on time for a department

if {@Count Admins Dept}=0 then 0

else round(({@Curt4}/{@Count Admins Dept})*100)

Accepted Solutions (1)

Accepted Solutions (1)

DellSC
Active Contributor
0 Kudos

You can right-click on the number after you put the formula on the report and select "Format...". On the Number tab you can format the number of digits behind the decimal. You would also take the "Round" out of the formula. The way you have it configured it will round to the nearest whole number.

Also, Crystal has a "percentage" operator so that you don't have to divide and then multiply by 100. Using it, your formula would look like this:

if {@Count Admins Dept}=0 then 0
  else {@Curt4} % {@Count Admins Dept}

-Dell

Answers (0)