View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.misc
Jim Thomlinson Jim Thomlinson is offline
external usenet poster
 
Posts: 5,939
Default protect more than one sheet at a time

The only way to do it is with code something like this...

Sub ProtectAll()
dim wks as worksheet

on error resume next
for each wks in worksheets
wks.Protect Password:="Tada"
next wks
end sub

Sub UnprotectAll()
dim wks as worksheet

on error resume next
for each wks in worksheets
wks.UnProtect Password:="Tada"
next wks
end sub
--
HTH...

Jim Thomlinson


"jbJB" wrote:

How can I protect more than one sheet at a time. If I select all sheets in a
workbook, the dropdown menu will not allow me to protect all sheets at once.
Instead I have to manually protect each sheet which can be very
timecomsumming if I have over 50 sheets in a workbook.