Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

IIF statement in access reports. 1

Status
Not open for further replies.

frankcpl

Technical User
Mar 16, 2007
77
US
I am trying to check a yes no field and display Personal and Business.

I have tried If, Then Statement

And tried IIF statement. Neither is working. Could someone look at this and give a hand in figuring out why it will not work.

I create an unbound label named Typelbl. I am referencing a Yes/No box.

If Yes/No.value = Yes Then
Typelbl.Caption = Personal
Else
Typelbl.Caption = Business
Endif

This doesn't work and I have also tried:

=IIF([Yes/No]="yes","Personal","Business")
That still didn't work.

I have tried putting the code in the report open(), Label AfterUpdate() and a variety of other places and still it isn't working.
 
OMG!!!! I fill so stupid. I never even thought of using a text box.

Thank you very much for your help I have messed with this thing for hours and never once tried it in a text box.

Again, Thank you.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top