iff statement needs to place two different remarks.

  • Thread starter Thread starter Garyj
  • Start date Start date
G

Garyj

Guest
I have a text box that reads

=IIf([PTODESC]="SICK","UNPLANNED")

What I want to do is to have two types of message in this box based on the response of another box.

In the text box named "PTODESC" I can select either sick or vacation. This is fine. What want the second text box to do is if I select Sick and message displays UNPLANNED as you see the above code does. How do I get the code to perform two task. If I select Vacation the same text box which displayed UNPLANNED will now say PLANNED.

I hope I explained this OK.

Thanks
 
Try this:

Code:
=IIf([PTODESC]="SICK","UNPLANNED",IIf([PTODESC]="VACATION","PLANNED"))

You can keep adding more IIf's if need be.

Hope it helps.

Peter
 
Iff statement needs to place two different remarks

Thanks it work great.
 

Users who are viewing this thread

Back
Top Bottom