Option Explicit Sub ProtectAllSheets() ' Written by Philip Treacy, http://www.myonlinetraininghub.com/author/philipt ' My Online Training Hub http://www.myonlinetraininghub.com/protect-and-unprotect-all-sheets-in-a-workbook ' June 2014 Dim WSheet As Worksheet Dim Pwd As String Application.ScreenUpdating = False Pwd = InputBox("Enter the password to protect all worksheets", "Enter Password") If Pwd = vbNullString Then NoPassword End If For Each WSheet In Worksheets WSheet.Protect Password:=Pwd Next WSheet Application.ScreenUpdating = True End Sub Sub UnProtectAllSheets() ' Written by Philip Treacy, http://www.myonlinetraininghub.com/author/philipt ' My Online Training Hub http://www.myonlinetraininghub.com/protect-and-unprotect-all-sheets-in-a-workbook ' June 2014 Dim WSheet As Worksheet Dim Pwd As String Application.ScreenUpdating = False Pwd = InputBox("Enter the password to unprotect all worksheets", "Enter Password") If Pwd = vbNullString Then NoPassword End If On Error Resume Next For Each WSheet In Worksheets WSheet.Unprotect Password:=Pwd Next WSheet If Err <> 0 Then MsgBox "The password you entered is incorrect. All worksheets are still protected.", vbCritical, "Incorrect Password" End If On Error GoTo 0 Application.ScreenUpdating = True End Sub Sub NoPassword() MsgBox "You didn't enter a password. This macro will not continue.", vbCritical + vbOKOnly, "No password entered." Application.ScreenUpdating = True End End Sub