robertdodson1979
New Member
- Joined
- May 30, 2014
- Messages
- 7
Hopefully this will be a quick fix question.
I am attempting to hide a dozen checkboxes based on the value of a cell being "1" (results of a true/false expression). This seems like such a simple task, but I am failing anyway. I realize it is probably a syntax issue, but I'm not seeing it, probably because I am pretty green on VBA. I DID search first, but results mostly referred to using another checkbox and such
Thanks in advance for you time!
I am attempting to hide a dozen checkboxes based on the value of a cell being "1" (results of a true/false expression). This seems like such a simple task, but I am failing anyway. I realize it is probably a syntax issue, but I'm not seeing it, probably because I am pretty green on VBA. I DID search first, but results mostly referred to using another checkbox and such
Code:
Private Sub HideCheckboxes(ByVal Target As Range)
If ActiveSheet.Range("B1").Value = "1" Then
ActiveSheet.CheckBoxes("CheckBox1").Visible = False
Else
ActiveSheet.CheckBoxes("CheckBox1").Visible = True
End If
End Sub
Thanks in advance for you time!