Unprotect multiple sheets at once.

N

Naseralabbas

How to unprotect multiple sheets. When selecting multiple protected
sheets in excell 2002, the " unprotect sheet " is not active. Is there
a way to do it.
 
G

Gord Dibben

Only through VBA.

Sub ProtectAllSheets()
Application.ScreenUpdating = False
Dim n As Single
For n = 1 To Sheets.Count
Sheets(n).Protect password:="justme"
Next n
Application.ScreenUpdating = True
End Sub

Sub UnprotectAllSheets()
Application.ScreenUpdating = False
Dim n As Single
For n = 1 To Sheets.Count
Sheets(n).Unprotect password:="justme"
Next n
Application.ScreenUpdating = True
End Sub

Gord Dibben Excel MVP
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top