I would greatly appreciate some help with the following code please... I know what is causing the problem from reading up on it but I have no idea as to how to rewrite the code...
Here is the code...
Private Sub Row1_Click()
With Range("B14:D14,F14:H14")
If .Cells(1).Locked Then
If InputBox("Enter password to enable editing?") = "mypassword" Then
MsgBox "Unlocked for editing"
.Locked = False
Else
MsgBox "Incorrect password!"
End If
Else
.Locked = True
MsgBox "Row now locked!"
End If
End With
End Sub
and the error occurs on the line .Locked = False
I have tried relocating the line but that only produces other errors...
Would really appreciate some help and the chance to increase my knowledge...
Many thanks in advance...
Moderator Note:
Pls use code tags around your code next time as per forum rules.
Bookmarks