Full Version: Remove 0 in Report Detail Section
UtterAccess Discussion Forums > Microsoft® Access > Access Reports
mkkashif
Dear Sir.
I want to remove the 0 from the detail section.
means if there is 0 in any field it's don't show in the report
what is method to do that.
thanks
malcolmd83
Here is a possible solution. Select the field(s) you want to not display "0", and choose "Conditional Formatting" from the "Format" menu. Then make if "equal to"..."0", format the text white. That will "hide" the value from view onscreen, and when printed. Just an idea...
tunkefer
Assume the text control in your report detail currently has its ControlSource set to "FieldOne" in the table. Change the ControlSource to:

= IIF([FieldOne]=0,"-",[FieldOne])

which replaces zero values with a dash, otherwise it displays the value. You can replace the "-" with a "" to produce a blank.

TomU
mkkashif
hello thanks for your help .
where to put the code.= IIF([FieldOne]=0,"-",[FieldOne])
is in the control source if i do that it shows the error.
i have debit field.
mkkashif
=IIf([Debit]=0,"-",[Debit])
i put this code in control source.it's not working and giving error
any one has any idea.
AJS
No need to make it a calculated value or muck around with conditional formatting.

Set the format property of any text box where you do not wish to display zeroes to
0.00;;""

That format will display 2 decimal places if the number is positive or negative, and nothing in the case of a zero or null.

hope this helps
-AJ
mkkashif
Thanks It's very Easy and very proper way.
you are real vip and every vip has vip treatment like you.
thanks it's help Ajs
AJS
You are welcome, and I'm quite glad to help.

-AJ
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.