OnChange event attached to tick box

J

jowashy

Arrgh please help

I have a spreadsheet that has two tick boxes. The second tick box
mustnt show until the first has been ticked. How do I do it.

Many thanks in desperation
 
N

Norman Jones

Hi Jowashy.

Try:

'=========>>
Private Sub CheckBox1_Click()
With Me
.CheckBox2.Visible = _
.CheckBox1.Value = True
End With
End Sub
'<<=========


This is event code and should be pasted
into the worksheets's code module (not a
standard module and not the workbook's
ThisWorkbook module):

Right-click the worksheet's tab |
Select 'View Code' from the menu
Paste the code
Alt-F11 to return to Excel.
 
F

FSt1

hi
Private Sub CheckBox1_Click()
If CheckBox1.Value = True Then
CheckBox2.Visible = True
Else
CheckBox2.Visible = False
End If
End Sub

regards
FSt1
 
J

jowashy

Hi Jowashy.

Try:

'=========>>
Private Sub CheckBox1_Click()
With Me
.CheckBox2.Visible = _
.CheckBox1.Value = True
End With
End Sub
'<<=========

This is event code and should be pasted
into the worksheets's code module (not a
standard module and not the workbook's
ThisWorkbook module):

Right-click the worksheet's tab |
Select 'View Code' from the menu
Paste the code
Alt-F11 to return to Excel.

Fantastic. Ill try it immediately. Thanks
 
B

Britney

Hi Norman
I send you an email as I have the same problem as Jowashy. I tried your code
but it didn't work. Is there any other way to solve this problem

thanks
Britney
 

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