Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I have a shared worksheet that needs to have columns
protected. I also need filters on. I can do it with VB in a non shared worksheet. Must I use VB and can you help? Thanks Gary |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Before xl2002:
if the workbook isn't shared, you can protect the sheet in code and allow the existing autofilter arrows to work: Option Explicit Sub auto_open() With Worksheets("Sheet1") .Protect Password:="hi", _ DrawingObjects:=False, Contents:=True, Scenarios:=True, _ userinterfaceonly:=True .EnableAutoFilter = True End With End Sub It needs to be reset each time you open the workbook. (excel doesn't remember it after closing the workbook.) (you could use the workbook_open even under ThisWorkbook, too.) ==== But when the workbook is shared, you can't change the worksheet protection--so this code will fail. ==== Starting with xl2002, there's an option under tools|protection that allows existing autofilters to work. And they work on a shared workbook. I think you'll have to upgrade to xl2002 (if you're not there already) to use autofilter on a protected worksheet in a shared workbook. I don't think that there's a workaround in earlier versions. Gary wrote: I have a shared worksheet that needs to have columns protected. I also need filters on. I can do it with VB in a non shared worksheet. Must I use VB and can you help? Thanks Gary -- Dave Peterson |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Spell Check in Protected Worksheet & Shared Workbook | Excel Discussion (Misc queries) | |||
Spell Check in Protected Worksheet & Shared Workbook continued | Excel Discussion (Misc queries) | |||
Is it possible to use filters in a protected worksheet? | Excel Discussion (Misc queries) | |||
Filters on Protected Worksheets | Excel Programming | |||
shared workbooks - protected worksheet - insert rows | Excel Programming |