If statement for Query Maybe???

Gretchen

Registered User.
Local time
Today, 23:11
Joined
Feb 25, 2002
Messages
48
Here's my problem:

I have OrgName field in a form. The subform on this form has the actual CtrName field. The CtrName field is only filled in if it is different from the OrgName. When pulling the query for labels, I need the query to pull the correct name (address/city/state/zip will be same for both). If the CtrName is blank, I need the query to use the OrgName. If the CtrName is completed, I need the query to use that field rather than the OrgName. This sounds like an If statement to me; but that's beyond my knowledge. How can I get this to work for my users?

Thanks
 
You'd be better to look up the Nz() function in the help.
 
Try LabelName: IIf(Nz(CtrName,"")="", Orgname,CtrName)
 
Thanks so much to you both! I'll try these and if I get too lost, I'll post again *grin*

:)
 
Thank you!!

Thank you Mile-O-Phile and Neileg!!! A big hug to you Neileg for the exact wording! *hugs* You have made my user's day!!! (as well as mine) Thanks again !!!
 

Users who are viewing this thread

Back
Top Bottom