J
johnhildreth
This should be easy...how does one determine which of a set of grouped
option buttons is selected? Let's say I have 4 option buttons
(optionbutton1, optionbutton2, etc) with groupname set to Season. The
user selects....winter, which corresponds to optionbutton4. I can
check each one...
If Userform1.OptionButton1.Value = -1 Then x = 1
If Userform1.OptionButton2.Value = -1 Then x = 2
If Userform1.OptionButton3.Value = -1 Then x = 3
If Userform1.OptionButton4.Value = -1 Then x = 4
but there MUST be a better way!! I have many groups and many, many
option buttons on my form. The above solution quickly becomes
tedious.
Thanks,
John
option buttons is selected? Let's say I have 4 option buttons
(optionbutton1, optionbutton2, etc) with groupname set to Season. The
user selects....winter, which corresponds to optionbutton4. I can
check each one...
If Userform1.OptionButton1.Value = -1 Then x = 1
If Userform1.OptionButton2.Value = -1 Then x = 2
If Userform1.OptionButton3.Value = -1 Then x = 3
If Userform1.OptionButton4.Value = -1 Then x = 4
but there MUST be a better way!! I have many groups and many, many
option buttons on my form. The above solution quickly becomes
tedious.
Thanks,
John