IIF statement on a Form

penwood

Registered User.
Local time
Today, 04:26
Joined
Nov 26, 2005
Messages
51
I have 2 text fields on my form named SOLDTONAME AND SHIPTONAME.

Many times they are the same spelling of a customers name. To eliminate clutter from my input screen, i want to make an IIF statement.

If the 2 names are spelled exactly the same, then make the ShiptoName form field empty. The data is coming from a Qry. I tried the following but get #Error.

In the CONTROL SOURCE of the ShiptoName form field I used:

=IIf([SoldtoName]=[ShiptoName]," ",[ShiptoName])

Where am i wrong? thanks
 
Someone figured out my problem. I needed to have the field names on the form spelled different than the control source qry names.
 

Users who are viewing this thread

Back
Top Bottom