protect worksheet with check box
Try this
Private Sub CheckBox1_Click()
With Worksheets("Sheet1")
ActiveSheet.Unprotect "pass"
Cells.Locked = False
End With
If CheckBox1 = True Then
Rows("1:68").Locked = True
ActiveSheet.Protect "pass"
Else: Rows("1:68").Locked = True
End If
End Sub
|