assign event procedures to an option group?

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I would like the three options in a group on a form to call different event
procedures. I would like 2 of 3 to open combo box controls, and the third
option to open a subform. Can I do that?
 
I would like the three options in a group on a form to call different event
procedures. I would like 2 of 3 to open combo box controls, and the third
option to open a subform. Can I do that?

You can put code in the AfterUpdate event of an option group control -
but the events you're suggesting are not making sense to me. You don't
"open" combo boxes or subforms! Such controls just sit there on your
form waiting to be used.

Do you want to just set focus to them, or drop down the combo from
code, or what?

John W. Vinson[MVP]
 
Okay, I see that my question is confusing. I have an option group to select
one of three options. Depending upon the selection, I would like to then
narrow that selection further. If the first option is selected, I would like
to then go to a different form to enter information. For either of the other
options, I would like to then choose from or add to an existing list. Like,
for instance, friend, family, or stranger, with a list of friends, a list of
family members, or a form to add info for a stranger.
 
Okay, I see that my question is confusing. I have an option group to select
one of three options. Depending upon the selection, I would like to then
narrow that selection further. If the first option is selected, I would like
to then go to a different form to enter information. For either of the other
options, I would like to then choose from or add to an existing list. Like,
for instance, friend, family, or stranger, with a list of friends, a list of
family members, or a form to add info for a stranger.

Then you would use appropriate code in the option group's AfterUpdate
event. The first option would use the OpenForm method (as might the
'add to an existing list' option.

I still have no idea what you expect to see on the form. If you have a
combo box, what effect should the option group have on the combo box?


John W. Vinson[MVP]
 
You could have the combo box(es) hidden on the form and then make them
visible if the appropriate option were selected.

However, that will not allow addition to a set of values or table
behind a combo box so I am still not sure what you are trying to do.

As indicated above it could allow further selection of an entry in a
now visible combo box in order for other processes to be done.

Ron
 
Back
Top