Option Groups

N

Nancy

I'm a VB6 VB.Net developer that's now developing in
Access 2000. On one of my forms, I have created an Option
Group that contains two option buttons. I want one of the
option buttons to be selected by default when the form
loads. In VB6 and VB.Net, that's simple, you just set the
checked property of the chosen button to true either in
design time or programatically at run time.

How do you do this in VBA? There is no checked property
or anything that comes close to it in VBA.

Thanks!
 
W

Wayne Morgan

Set the default value of the option group to the value of the option button you want to be
default.

Each button should have an Option Value property, this is what you would set as the
default value of the option group (frame).
 
A

Alan

Hi Nancy,

Set the "default value" property (for the option group
frame) to:
1 (this will set button 1 as the default)
or
2 (this will set button 2 as the default)

Hope this helps

Alan
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top