Not sure what you mean. Do you want records with a particular field = 0 to not print, or do you want BLANK to appear in place of 0 whenever that occurs?
Please clarify. "Get it right the first time, that's the main thing..."
Okay. You need to base your report on a query, if not done so already. For the field that you want to hide the 0's, enter the following expression as the FIELD value:
1. In the query:
Create a new column and make the field
BlahName:IIf([Field]= 0, "",[Field])
<"BlahName" is any name that you make up to recognize the field, "Field" is the name of the field in the table or query which you want to remove the zeroes from>
Basically, what the expression is doing is saying "if the field's value is equal to zero, then disply an empty string ("", in other words, BLANK), otherwise, show the value of the field."
Feel free to change the "" into any string that you would want to use to replace the zeros (such as "none" or whatever)
Then on the report, change the source of the control to this new field (don't forget to change the name of the control so you don't get an error)
2. In the report
Create a new control and set its souce to
IIf([Control]= 0, "",[Control])
<"Control" is the name of the control that you want to test for zeroes.>
Set the original control's visibility to "No"
I personally like to do these calculations in the query since it is then available to other forms/reports/queries that use it, but you might find that putting it on the report will improve performance.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.