diobbi
Technical User
- Aug 19, 2002
- 6
I need to perform a calculation that takes 2 fields and divides them to come up with a number. I then need to format that number as a percent. If either of these fields is blank, I want to put "N/A" on the report. Here is the formula:
if IsNull({StubResultsSub.EBIT}) then "n/a" else
({StubResultsSub.EBIT}/{StubResultsSub.LATESTSALES})*100
The problem is it won't let me do this. I keep getting:
A string is required after the else. I could convert the formula to a string using cstr however then I can't format the result to display the percent sign. Does anyone know how to do this? Thanks.
Deborah
if IsNull({StubResultsSub.EBIT}) then "n/a" else
({StubResultsSub.EBIT}/{StubResultsSub.LATESTSALES})*100
The problem is it won't let me do this. I keep getting:
A string is required after the else. I could convert the formula to a string using cstr however then I can't format the result to display the percent sign. Does anyone know how to do this? Thanks.
Deborah