#Num, how to get a 0 value instead of #Num

Czeszyn

Registered User.
Local time
Today, 11:16
Joined
Oct 14, 2014
Messages
128
I am getting a #Num! because sometimes there is no data to be entered. The formula I have does work, but what do I need to add to it so that it will produce a 0 value if no data is required.

[TotScrwBlank]/[TotalAmount]

Also, by adding anything to this formula, would this make me lose my data that is in the database already?

I hope that some one can help.

Thank you in advance.
Tony:banghead:
 
Hi Ranman256
Thank you for responding. I tried what you said and I get the following:

The expression you entered has a function containing the wrong number of arguments.

I checked to make sure I entered it as you have it too.

Tony.
 
czeszyn,

I think ranman just had an extra bracket.
Here is his suggestion (revised)

iif ([TotalAmount] = 0,0,[TotScrwBlank]/[TotalAmount])
 
No data is different than a value of 0. I'm pretty sure once you get the syntax right Ran's method will fail for records where either of those fields is Null.
 
Thank you everyone, that did fix my error. I noticed that I had another one like that:

[TotScrwBlank]/([TotScrwBlank]+[TotParts])*1000000

so would I rewrite that as:

iff(([TotScrwBlank]+[TotParts])*1000000)=0,0,
[TotScrwBlank]/([TotScrwBlank]+[TotParts])*1000000)

Thank you again.
Tony
 
Thank you I got it to work. You all have been a great help.

Tony
 

Users who are viewing this thread

Back
Top Bottom