code to hide check boxes
I want a group of check boxes to only be visible if another check box is selected. When the other check box is not selected, I want the group to be invisible. Also, I need to know if I should put the code in the Worksheet code or the Workbook code. Thanks. Matt
|
code to hide check boxes
Matt,
Try this code Private Sub CheckBox1_Click() With CheckBox1 CheckBox2.Visible = .Value CheckBox3.Visible = .Value CheckBox4.Visible = .Value CheckBox5.Visible = .Value End With End Sub put it in the worksheet code module. I assume you arev using control checkboxes. not forms -- HTH Bob Phillips ... looking out across Poole Harbour to the Purbecks (remove nothere from the email address if mailing direct) "Matt" wrote in message ... I want a group of check boxes to only be visible if another check box is selected. When the other check box is not selected, I want the group to be invisible. Also, I need to know if I should put the code in the Worksheet code or the Workbook code. Thanks. Matt |
code to hide check boxes
I am using form check boxes. Is this a problem?
----- Bob Phillips wrote: ----- Matt, Try this code Private Sub CheckBox1_Click() With CheckBox1 CheckBox2.Visible = .Value CheckBox3.Visible = .Value CheckBox4.Visible = .Value CheckBox5.Visible = .Value End With End Sub put it in the worksheet code module. I assume you arev using control checkboxes. not forms -- HTH Bob Phillips ... looking out across Poole Harbour to the Purbecks (remove nothere from the email address if mailing direct) "Matt" wrote in message ... I want a group of check boxes to only be visible if another check box is selected. When the other check box is not selected, I want the group to be invisible. Also, I need to know if I should put the code in the Worksheet code or the Workbook code. Thanks. Matt |
code to hide check boxes
Matt,
Yes it is because AFAIK you can't hide the forms checkbox. SO if you want this facility, best to switch tow controls checkboxes. -- HTH Bob Phillips ... looking out across Poole Harbour to the Purbecks (remove nothere from the email address if mailing direct) "Matt" wrote in message ... I am using form check boxes. Is this a problem? |
All times are GMT +1. The time now is 11:34 AM. |
Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com