Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
mcwhirter
 
Posts: n/a
Default unprotect/protect grouped worksheets in excel

I have multiple sheets in multiple work books and want some to be protected
and others not. I wanted to break links to another work book but found that
the protected sheets would not allow it. I tried to group the sheets
together and then unprotect them but unprotect in the tools menu was greyed
out. How can I unprotect multiple work sheets? Very time consuming doing
this one sheet at a time for 100 sheets.
  #2   Report Post  
Aussie CPA
 
Posts: n/a
Default

The below code may assist you. Just copy it into a vba module. Please note
where the code says "RTGPAW" this is the password specified for each sheet.
If you have different passwords for each sheet this will not work. If you
don't specify a password then take this section out. Once you do this you can
assign the Macro to a toolbar button if you like. The code can be saved in
either your personal.xls workbook or the individual workbook you are using.


Hope this helps.


Sub UnProtect()
'
' UnProtection Macro
' Macro written by Adam Wood
'

Dim Sheetnumber
Sheetnumber = 1
Do
ActiveWorkbook.Worksheets(Sheetnumber).Activate
ActiveWorkbook.Worksheets(Sheetnumber).UnProtect "rtgpaw"
Sheetnumber = Sheetnumber + 1
Loop Until Sheetnumber = ActiveWorkbook.Worksheets.Count
ActiveWorkbook.UnProtect "rtgpaw"

"mcwhirter" wrote:

I have multiple sheets in multiple work books and want some to be protected
and others not. I wanted to break links to another work book but found that
the protected sheets would not allow it. I tried to group the sheets
together and then unprotect them but unprotect in the tools menu was greyed
out. How can I unprotect multiple work sheets? Very time consuming doing
this one sheet at a time for 100 sheets.

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Excel 2003 FAILS, but Excel 2000 SUCCEEDS ??? Richard Excel Discussion (Misc queries) 2 May 13th 23 11:46 AM
Appending excel worksheets Rbuzard Excel Worksheet Functions 3 September 13th 05 11:57 AM
Excel Range Value issue (Excel 97 Vs Excel 2003) Keeno Excel Discussion (Misc queries) 2 June 13th 05 02:01 PM
excel buttons grouped on taskbar tryer Excel Discussion (Misc queries) 4 June 9th 05 01:01 PM
How to send Excel 2000 worksheets to Excel 2003? SecretarybyBarry Excel Discussion (Misc queries) 2 February 21st 05 05:28 PM


All times are GMT +1. The time now is 11:41 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"