Linking ActiveX Controls

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I want to have a checkbox or two, that only become active or available for
selection when a specific option button is selected. Can / how do I do this?
 
I guessed that these controls were on a worksheet.

I went into designmode and double clicked on one of the optionbuttons and pasted
this code:

Option Explicit
Private Sub OptionButton1_Change()

Me.CheckBox1.Enabled = CBool(Me.OptionButton1.Value)
Me.CheckBox2.Enabled = CBool(Me.OptionButton1.Value)

End Sub
 

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

Back
Top