I'm trying to format specific values in the same column of crystal report.
The column should show all the other numbers as decimals, except for 100. 100 should be shown as a whole number.
I'm showing {@Numeric2} in the detail of the column.
This is what I did.
In format field, Number tab, customize, For Decimal I entered following formula;
If {@Numeric2} = 100 Then 1 Else 1.0
The problem is that it is not rounding 100 as a whole, instead, showing 100 as a decimal as well like 100.0
Two options:
1. Right-click the field > Format Field > Number tab > Customize... > Use Rounding and Decimal formulas here
2. another option is to convert the number to string like:
If { @Numeric2 } = 100 then "100" else Totext ( {@Numeric2 } , 2)