Dear Demigods,
I am using the following VBA:
The codes works well until i come to protecting the worksheet.
I leave B14 unLocked (so the code still works), and i also leave some cells within 15:38 unLocked (for example C16, Q16, T37 etc).
When i then protect the worksheet, i get the run-time 1004 error together with
"Unable to set the Hidden property of the Range Class"
Any ideas please?
Best regards
manc
I am using the following VBA:
Code:
Private Sub Worksheet_BeforeDoubleClick(ByVal Target As Range, Cancel As Boolean)
If Target.Address(0, 0) = "B14" Then
Cancel = True
Rows("15:38").Hidden = Not Rows("15:38").Hidden
End If
End Sub
The codes works well until i come to protecting the worksheet.
I leave B14 unLocked (so the code still works), and i also leave some cells within 15:38 unLocked (for example C16, Q16, T37 etc).
When i then protect the worksheet, i get the run-time 1004 error together with
"Unable to set the Hidden property of the Range Class"
Any ideas please?
Best regards
manc