If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Display Modes |
#1
|
|||
|
|||
Protecting Selected Sheets
This macro used to work...I am now using Excel 2003....it appears to fail at
line ... sht.Protect password="lock" Any help would be appreciated ******************************* Sub ProtectAllSheets() Sheets("Sheet1").Select Sheets("Sheet2").Select Sheets("Sheet9").Select Sheets("Sheet11").Select For Each sht In Sheets sht.Protect Password:="lock" Next sht End Sub ******************************* Thanks Steve |
#2
|
|||
|
|||
Protecting Selected Sheets
I probably should have explained better what I'm attempting to do with this
macro... I want to be able to select certain sheets within a workbook and protect them with a password. I'd like to have a subsequent macro that would do the opposite....select same sheets and un-protect them. Thanks |
Thread Tools | |
Display Modes | |
|
|