Need to build an Iif statement based on values coming up 0 to not show.

Need to build an Iif statement based on values coming up 0 to not show.

I have the following control source in a text box:


Open in new window

But there are some values that come up 0.
I want to change this to where if it's 0 - then come up blank even thought it's a numeric field.

I know I can use Iif statement to make this work but having trouble with the syntax:
I used this and get the #error

iif(Sum(Nz([01WorkHours],0)) = 0, Null)

How do I change the above to make it work?

Thank you in advance.
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Paul Cook-GilesSenior Application DeveloperCommented:
=iif(Sum(Nz([01WorkHours],0)) = 0, "")
NorieAnalyst Assistant Commented:
Have you tried using a custom format for the field/textbox?

You could try something like this to show 0s as blank.

Gustav BrockCIOCommented:
You miss the second condition parameter:


Open in new window

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Microsoft Access

From novice to tech pro — start learning today.