I have a macro that Protects all sheets in my workbook, but when used, it is locking cells that should be Unlocked.
Here is the Code:
>>> use code - tags <<<
Am I missing something?
Here is the Code:
>>> use code - tags <<<
Code:
Sub Protect_All()
Dim xWs As Worksheet
'turn screen updating off
Application.ScreenUpdating = False
'loop through each sheet and protect with a password
For Each xWs In ActiveWorkbook.Worksheets
xWs.Protect Password:="Password", _
AllowFormattingColumns:=True, _
AllowFormattingRows:=True, AllowSorting:=True, AllowFiltering:=True
Next xWs
'turn screen updating on
Application.ScreenUpdating = True
End Sub
Am I missing something?
Last edited by a moderator: