Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I have 3 groups of optionbutton and an 'Ok' commandbutton. When i pres
'Ok' how do I get the captions of the 3 optionbuttons (one in eac group), which are true. Thanks for any help -- Message posted from http://www.ExcelForum.com |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
This assumes that the option button groups are contained
inside frames. I don't think it's necessary to run separate loops for each group but, at least for illustrative purposes, here's my rendition: Private Sub OKButton_Click() Dim Ctl As Control, OB As Control For Each Ctl In Me.Controls If TypeOf Ctl Is msForms.Frame Then For Each OB In Ctl.Controls If OB Then MsgBox OB.Caption Next End If Next End Sub Regards, Greg -----Original Message----- I have 3 groups of optionbutton and an 'Ok' commandbutton. When i press 'Ok' how do I get the captions of the 3 optionbuttons (one in each group), which are true. Thanks for any help. --- Message posted from http://www.ExcelForum.com/ . |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
optionbutton - three options | Excel Discussion (Misc queries) | |||
Optionbutton troubles | Excel Worksheet Functions | |||
OptionButton. Reset to 0 | New Users to Excel | |||
How Do I Tab From An OptionButton To A TextBox | Excel Discussion (Misc queries) | |||
OptionButton problem | Excel Programming |