Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
Macro to Protect Mult Sheets / but allow Pivot Tables...
Hello Group,
I have this code that i found in searching the forums, but i have a question. I need to allow them to access two unlocked cells and a pre-exsisting pivot table. I want to lock the rest of the sheet. Can someone else me improve this code please? :) Sub LockEm() Dim i As Long Dim PW As String Dim WS As Worksheet PW = InputBox("Password:") On Error GoTo MyErr For Each WS In ActiveWorkbook.Worksheets WS.Protect (PW) Next MsgBox i & " errors while protecting", vbInformation Exit Sub MyErr: i = i + 1 Resume Next End Sub Thank you. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Pivot tables and work sheets | Excel Worksheet Functions | |||
Macro to protect multiple sheets? | Excel Worksheet Functions | |||
Use Macro to protect choosen sheets in workbook | Excel Discussion (Misc queries) | |||
#REF in Sheets that refer to Pivot Tables | Excel Discussion (Misc queries) | |||
Copying sheets with pivot tables | Excel Worksheet Functions |