A
Amit
Hi,
I have an unbound combo-box in a form (the form is not
based on any table or query). How can I force the user
select a value from the combo-box?? There's no 'required'
property for it.
The combo-box is the first control on the form. In
addition, there are 3 buttons to open different forms, but
all of them require the user to select a Program.
What I've tried so far:
1. In the 'Validation Rule', I have the following:
"=[cboProgramID_frmMenu_2].[Value] Is Not Null"
2. I tried putting code in the OnExit event of the
comboBox to check for the value, and if null, then set
focus to combo-box.
3. In the OnClick event of the button, I put code to check
for the value of combo-box and if null, then set focus to
combo-box and exit.
None of these worked. For 3., I get a syntax error for
missing ProgramID. But, that's not quite the message I'd
like to display as it's pretty cryptic.
Is there a better way to accomplish what I'm trying to do?
Am I missing something really simple here??
Thanks for any help.
-Amit
I have an unbound combo-box in a form (the form is not
based on any table or query). How can I force the user
select a value from the combo-box?? There's no 'required'
property for it.
The combo-box is the first control on the form. In
addition, there are 3 buttons to open different forms, but
all of them require the user to select a Program.
What I've tried so far:
1. In the 'Validation Rule', I have the following:
"=[cboProgramID_frmMenu_2].[Value] Is Not Null"
2. I tried putting code in the OnExit event of the
comboBox to check for the value, and if null, then set
focus to combo-box.
3. In the OnClick event of the button, I put code to check
for the value of combo-box and if null, then set focus to
combo-box and exit.
None of these worked. For 3., I get a syntax error for
missing ProgramID. But, that's not quite the message I'd
like to display as it's pretty cryptic.
Is there a better way to accomplish what I'm trying to do?
Am I missing something really simple here??
Thanks for any help.
-Amit