Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 16
Default Turning Filters ON in a Protected Shared Worksheet

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   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2,824
Default Turning Filters ON in a Protected Shared Worksheet

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
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
Spell Check in Protected Worksheet & Shared Workbook DaveyC4S Excel Discussion (Misc queries) 6 October 28th 05 12:50 PM
Spell Check in Protected Worksheet & Shared Workbook continued DaveyC4S Excel Discussion (Misc queries) 1 October 25th 05 06:15 PM
Is it possible to use filters in a protected worksheet? jpici Excel Discussion (Misc queries) 1 March 10th 05 08:39 PM
Filters on Protected Worksheets CiaraG[_3_] Excel Programming 2 November 20th 03 11:10 AM
shared workbooks - protected worksheet - insert rows mika. Excel Programming 1 September 11th 03 01:51 AM


All times are GMT +1. The time now is 11:50 PM.

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

About Us

"It's about Microsoft Excel"