Checkbox Macro

  • Thread starter Thread starter grin2000
  • Start date Start date
G

grin2000

I have a checkbox of which I need macro for. The only thing I need it t
do it if I click on it and it is checked, a button next to it shoul
appear which is already made(button's name is "Thread"). And if it i
not checked I don't want the button to be there. And the box starts of
as unchecked. THANK
 
Dear grin;

Use the code below;

Thanks, Greg

Private Sub CheckBox1_Change()
If CheckBox1.Value = True Then
Thread.Visible = True
ElseIf CheckBox1.Value = False Then
Thread.Visible = False
End If

End Sub



Private Sub UserForm_Activate()
Thread.Visible = False

End Sub
 
or more simply

Private Sub CheckBox1_Change()
Thread.Visible = Checkbox.Value
End Sub


--

HTH

Bob Phillips
... looking out across Poole Harbour to the Purbecks
(remove nothere from the email address if mailing direct)
 

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