ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   excel filter (https://www.excelbanter.com/excel-discussion-misc-queries/22137-excel-filter.html)

Pedro

excel filter
 
hi! I was trying to put a filter in a protected sheet in my workbook (Excel
2003)
It doesn't work. is there a way to put it working or it doesn't work at all?
thanks



Harald Staff

You must unprotect a sheet to add or remove filters.

HTH. Best wishes Harald

"Pedro" skrev i melding
...
hi! I was trying to put a filter in a protected sheet in my workbook

(Excel
2003)
It doesn't work. is there a way to put it working or it doesn't work at

all?
thanks





Arvi Laanemets

Hi

You must have an Open event for workbook (in ThisWorkbookGeneral):

Private Sub Workbook_Open()
Sheets("YourSheetName").Unprotect Password:="YourPassword"
Sheets("YourSheetName").Protect Password:="YourPassword",
UserInterfaceOnly:=True
Sheets("YourSheetName").EnableAutoFilter = True
' repeat the code above for every sheet, you want to allow to be
filtered
End Sub

--
When sending mail, use address arvil<attarkon.ee
Arvi Laanemets


"Pedro" wrote in message
...
hi! I was trying to put a filter in a protected sheet in my workbook

(Excel
2003)
It doesn't work. is there a way to put it working or it doesn't work at

all?
thanks





PS

thx.
i didn't explain myself the best way.
i added the filter in the unprotected sheet. then i protected it and now the
filter doesn't work.
i want to protect the sheet but leave the filter working..
can u help me resolving this question?

PS

"Harald Staff" escreveu:

You must unprotect a sheet to add or remove filters.

HTH. Best wishes Harald

"Pedro" skrev i melding
...
hi! I was trying to put a filter in a protected sheet in my workbook

(Excel
2003)
It doesn't work. is there a way to put it working or it doesn't work at

all?
thanks






Dave Peterson

If all your users are using xl2002+, you can protect the worksheet and allow the
autofilter to work (autofilter arrows are already applied).

It's an option near the bottom on the protect sheet dialog.

If any of your users are using xl2k or below, then you need a macro:

Use this in the Auto_open procedure in a General module:

Option Explicit
Sub auto_open()

Dim wks As Worksheet
Set wks = Worksheets("sheet1")

With wks
.Protect Password:="hi", userinterfaceonly:=True
.EnableAutoFilter = True
End With

End Sub

(you could use the workbook_open event under ThisWorkbook, too.)

This setting isn't remembered between closing/reopening the workbook. (So
Auto_open is a nice spot for it.)

Pedro wrote:

hi! I was trying to put a filter in a protected sheet in my workbook (Excel
2003)
It doesn't work. is there a way to put it working or it doesn't work at all?
thanks


--

Dave Peterson

PS

finally...
thx for your help..
now it works like I wanted...
thank you ...
carpe diem

Pedro Silva

"Dave Peterson" escreveu:

If all your users are using xl2002+, you can protect the worksheet and allow the
autofilter to work (autofilter arrows are already applied).

It's an option near the bottom on the protect sheet dialog.

If any of your users are using xl2k or below, then you need a macro:

Use this in the Auto_open procedure in a General module:

Option Explicit
Sub auto_open()

Dim wks As Worksheet
Set wks = Worksheets("sheet1")

With wks
.Protect Password:="hi", userinterfaceonly:=True
.EnableAutoFilter = True
End With

End Sub

(you could use the workbook_open event under ThisWorkbook, too.)

This setting isn't remembered between closing/reopening the workbook. (So
Auto_open is a nice spot for it.)

Pedro wrote:

hi! I was trying to put a filter in a protected sheet in my workbook (Excel
2003)
It doesn't work. is there a way to put it working or it doesn't work at all?
thanks


--

Dave Peterson


PS

finally it works like I wanted.
thx....

Pedro Silva

"Arvi Laanemets" escreveu:

Hi

You must have an Open event for workbook (in ThisWorkbookGeneral):

Private Sub Workbook_Open()
Sheets("YourSheetName").Unprotect Password:="YourPassword"
Sheets("YourSheetName").Protect Password:="YourPassword",
UserInterfaceOnly:=True
Sheets("YourSheetName").EnableAutoFilter = True
' repeat the code above for every sheet, you want to allow to be
filtered
End Sub

--
When sending mail, use address arvil<attarkon.ee
Arvi Laanemets


"Pedro" wrote in message
...
hi! I was trying to put a filter in a protected sheet in my workbook

(Excel
2003)
It doesn't work. is there a way to put it working or it doesn't work at

all?
thanks






PS

i forgot to put the "use autofilter" active...
but thank you fo your help..

Pedro Silva

"Harald Staff" escreveu:

You must unprotect a sheet to add or remove filters.

HTH. Best wishes Harald

"Pedro" skrev i melding
...
hi! I was trying to put a filter in a protected sheet in my workbook

(Excel
2003)
It doesn't work. is there a way to put it working or it doesn't work at

all?
thanks






icsonu

excel filter
 
Hello,
I didnt know how to insert a open event in a Workbook.
can u please help me out in applyng the following:
Private Sub Workbook_Open()
Sheets("YourSheetName").Unprotect Password:="YourPassword"
Sheets("YourSheetName").Protect Password:="YourPassword",
UserInterfaceOnly:=True
Sheets("YourSheetName").EnableAutoFilter = True
' repeat the code above for every sheet, you want to allow to be
filtered
End Sub


Regards,
icsonu

"Arvi Laanemets" wrote:

Hi

You must have an Open event for workbook (in ThisWorkbookGeneral):

Private Sub Workbook_Open()
Sheets("YourSheetName").Unprotect Password:="YourPassword"
Sheets("YourSheetName").Protect Password:="YourPassword",
UserInterfaceOnly:=True
Sheets("YourSheetName").EnableAutoFilter = True
' repeat the code above for every sheet, you want to allow to be
filtered
End Sub

--
When sending mail, use address arvil<attarkon.ee
Arvi Laanemets


"Pedro" wrote in message
...
hi! I was trying to put a filter in a protected sheet in my workbook

(Excel
2003)
It doesn't work. is there a way to put it working or it doesn't work at

all?
thanks






Don Guillett

excel filter
 
Look for the excel icon in the upper leftright clickinsert the code.

--
Don Guillett
Microsoft MVP Excel
SalesAid Software

"icsonu" wrote in message
...
Hello,
I didnt know how to insert a open event in a Workbook.
can u please help me out in applyng the following:
Private Sub Workbook_Open()
Sheets("YourSheetName").Unprotect Password:="YourPassword"
Sheets("YourSheetName").Protect Password:="YourPassword",
UserInterfaceOnly:=True
Sheets("YourSheetName").EnableAutoFilter = True
' repeat the code above for every sheet, you want to allow to be
filtered
End Sub


Regards,
icsonu

"Arvi Laanemets" wrote:

Hi

You must have an Open event for workbook (in ThisWorkbookGeneral):

Private Sub Workbook_Open()
Sheets("YourSheetName").Unprotect Password:="YourPassword"
Sheets("YourSheetName").Protect Password:="YourPassword",
UserInterfaceOnly:=True
Sheets("YourSheetName").EnableAutoFilter = True
' repeat the code above for every sheet, you want to allow to be
filtered
End Sub

--
When sending mail, use address arvil<attarkon.ee
Arvi Laanemets


"Pedro" wrote in message
...
hi! I was trying to put a filter in a protected sheet in my workbook

(Excel
2003)
It doesn't work. is there a way to put it working or it doesn't work at

all?
thanks








All times are GMT +1. The time now is 08:57 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com