I've managed to protect a worksheet, and prevent the user from typing in the cells. However how can I make it so that the user cannot select the cells?
Also when I click to unprotect the sheet it prompts me for a password and then doesn't seem to recognise the password
here is my code
Also when I click to unprotect the sheet it prompts me for a password and then doesn't seem to recognise the password
here is my code
Code:
Dim ws As Excel.Worksheet
Set ws = Sheets("MainMenu")
ws.Protect Password:="abc123", UserInterfaceOnly:=True
ws.Range("A1:L30").Locked = True
ws.Unprotect Password:="abc123"