#type error in calculated field

dkmoreland

Registered User.
Local time
Today, 12:11
Joined
Dec 6, 2017
Messages
129
I know you folks have seen this question a hundred times but I need to ask it anyway.:p

On my report, if the shipped quantity is equal to the order quantity, I need it to display 0 in the field. If it is not equal to the order quantity, I need it to display the value of the shipped quantity.

Here's my code for the field:
Code:
Iif([Shipping Qty:] <> [Order Quantity],[Shipping QTY:], 0)

I'm getting a #type error - both fields are number fields. I'm also getting a circular reference error.

Is my Iif statement incorrect or did I miss something else?

BTW - I know the field names are funky - I inherited this system.

Thanks in advance for any and all insight.
 
don't put it in the report, put it in the query.
then the report just shows the field.

if you must use the report, be sure to use TEXT BOX names. But sometimes the textbox and field names are the same.
 
Also make sure you precede the formula with "=".
 
Yes the field naming is bad as the OP herself pointed out in post #1
However using [], it will still work
 

Users who are viewing this thread

Back
Top Bottom