Conditional Statement Syntax

  • Thread starter Thread starter Jay
  • Start date Start date
J

Jay

Greetings! I have checked the Access Help, online help, tutorials, even the
Dummies reference, but I can't find the correct way to make this work:

I have a combo box field in a form with 5 text options. I'm trying to
create a situation where if a certain option is chosen, a user prompt appears
somehow on the screen, perhaps the background of another field on the form
changes color or something.

Basically, "if userschoice = option3 then acceptvalueandprompt else
justacceptvalue"

Thanks,
 
Greetings! I have checked the Access Help, online help, tutorials, even the
Dummies reference, but I can't find the correct way to make this work:

I have a combo box field in a form with 5 text options. I'm trying to
create a situation where if a certain option is chosen, a user prompt appears
somehow on the screen, perhaps the background of another field on the form
changes color or something.

Basically, "if userschoice = option3 then acceptvalueandprompt else
justacceptvalue"

Thanks,
What is the datatype of the bound column of the combo box?
Number?

Code that control's AfterUpdate event:
If [UserChoiceControl] = 3 Then
MsgBox "You selected # 3."
End If

Text?
If [UserChoiceControl] = "Option3" Then
MsgBox "You selected Option 3."
End If
 
Back
Top