XL2000: Macro Examples Using Option Button Controls on a UserForm (213549)
The information in this article applies to:
This article was previously published under Q213549 SUMMARY
There are two ways to group option buttons on a UserForm. To group the
controls, do either of the following:
- Place the option buttons inside a Frame control.
-or-
- Use the GroupName property to create a group.
Both of these methods create a group for the specified option buttons,
which makes each of the option buttons (within a group) mutually exclusive.
This means that when you click any option button in the group, all other
option buttons in the group are set to False.
Neither method is better than the other one. The method you choose depends on how you want to implement the project and whether you want to use a Frame control for each group on the UserForm or use macro code.
This article contains macro examples that use both methods. This article
also contains an example that illustrates a third method that does not
require grouping of option buttons.
REFERENCESFor more information about grouping option buttons, in the Visual Basic Editor, click Microsoft Visual Basic Help on the Help menu, type groupname property in the Office Assistant or the Answer Wizard, and then click Search to view the topic.
Then click to select the GroupName Property topic.
| Modification Type: | Minor | Last Reviewed: | 10/11/2006 |
|---|
| Keywords: | kbdtacode kbhowto kbProgramming KB213549 |
|---|
|