How do you create an option group using VBA?

  • Thread starter Thorn via AccessMonster.com
  • Start date
T

Thorn via AccessMonster.com

Is there a way to create an option group using VBA? I am trying to
dynamically create a form and I need to use an option group, but I can't
seem to figure out how to create the option group using VBA. I can create
the option buttons, but they don't work as an option group.
 
A

Allen Browne

Create the group first, and then specify that group as the parent for your
option buttons.

For example, if you already created an option group named "Group1" on Form1:
CreateControl("Form1", acOptionButton,, "Group1", ...
 
Top