Hello
I have a worksheet with an checkbox (CheckBox1) in cell Z6.
what code do, is hide 3 different sheets and some columns on other sheets. Everything works perfectly.
What I need to do now is to password protect that check box, so every time someone try to remove the mark from check box it asks for password.
Then person that has the access to this feature, enters the correct password followed by enter. Entering the password only need to work when you want to remove the mark from check box
Help is greatly appreciated
Best regards
Dedaluss
Sub CheckBox1_Click()
If Range("Z6").Value = True Then
Sheets("sheet1").Select
ActiveWindow.SelectedSheets.Visible = False
Sheets("sheet2").Select
ActiveWindow.SelectedSheets.Visible = False
Sheets("sheet3").Select
ActiveWindow.SelectedSheets.Visible = False
Sheets("sheet4").Select
Sheets("sheet4").Columns("S:W").Hidden = True
Sheets("sheet5").Columns("E:F").Hidden = True
Else
Sheets("sheet1").Visible = True
Sheets("sheet1").Select
Sheets("sheet2").Visible = True
Sheets("sheet2").Select
Sheets("sheet3").Visible = True
Sheets("sheet3").Select
Sheets("sheet4").Select
Sheets("sheet4").Columns("S:W").Hidden = False
Sheets("sheet5").Columns("E:F").Hidden = False
End If
End Sub
Bookmarks