dominiks
05-28-2013, 04:14 AM
Hi,
I know this may seem like a very basic question but I am really stuck on this one.
I have multiple active-x check-boxes and quite a few contain code to hide or display another work-book if checked or not, that is working fine but for one set of them I need some help with the code to make it do more.
I need to be able to hide or display a sheet when a check box is ticked but also when it conforms to value within another cell on the same sheet.
So the code that I am stuck with;
Public Sub CheckBox29_Click()
Range(O5) = "Schlumberger"
If CheckBox29.Value = True Then
Sheets("SLB TFO-Run1").Visible = True
Else
Sheets("SLB TFO-Run1").Visible = False
End If
End Sub
I need to specify that when the value of cell O5 is a word that the logic of the check box then decides which sheet to display. The same code would then be duplicated to allow 7 different words for O5.
Any help on this would be much appreciated.
Kind Regards
Dominik
I know this may seem like a very basic question but I am really stuck on this one.
I have multiple active-x check-boxes and quite a few contain code to hide or display another work-book if checked or not, that is working fine but for one set of them I need some help with the code to make it do more.
I need to be able to hide or display a sheet when a check box is ticked but also when it conforms to value within another cell on the same sheet.
So the code that I am stuck with;
Public Sub CheckBox29_Click()
Range(O5) = "Schlumberger"
If CheckBox29.Value = True Then
Sheets("SLB TFO-Run1").Visible = True
Else
Sheets("SLB TFO-Run1").Visible = False
End If
End Sub
I need to specify that when the value of cell O5 is a word that the logic of the check box then decides which sheet to display. The same code would then be duplicated to allow 7 different words for O5.
Any help on this would be much appreciated.
Kind Regards
Dominik