Filter on a protected page

  • Thread starter Thread starter WT
  • Start date Start date
W

WT

When I place filter on the column titles and then protect the page the
filters are inoperable. Any way to change that??
 
If you already have the outline/subtotals/autofilter applied, you can protect
the worksheet in code (auto_open/workbook_open??).

Option Explicit
Sub auto_open()
With Worksheets("sheet1")
.Protect Password:="hi", userinterfaceonly:=True
'.EnableOutlining = True
.EnableAutoFilter = True
'If .FilterMode Then
' .ShowAllData
'End If
End With
End Sub

It needs to be reset each time you open the workbook. (Earlier versions of
excel don't remember it after closing the workbook. IIRC, xl2002+ will remember
the allow autofilter setting under tools|Protection|protect sheet, but that
won't help when you're filtering via code.)
 
Thank you, I take it the only way is to use code. Does this code work in a
multi-user workbook (shared)?
 
I tried this and it doesn't seem to work with 2003. Do you have another
option?

Thanks,
Heidi
 
I figured out the filters> What about subtotals?

Heidi said:
I tried this and it doesn't seem to work with 2003. Do you have another
option?

Thanks,
Heidi
 
It worked fine for me in xl2003.

What part didn't work for you?

Post the code that you're having trouble with.

Personally, I wouldn't use subtotals and autofilters on the same worksheet.
They don't work well with each other.
 
I got this to work fine in 2003, but it fails again when workbook is shared :-(

WT said:
Thank you, I take it the only way is to use code. Does this code work in a
multi-user workbook (shared)?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Back
Top