If you name the procedure
Private Sub Workbook_Open()
as shown and place it in the ThisWorkbook module (as described), then when
you open the workbook without disabling macros, the code will run and allow
you to set filter criteria in a protected worksheet (the sheet with a
codename of Sheet1 in the example).
The catch is that the autofilter dropdowns must already be visible. To the
best of my recollection, this does not let you apply an autofilter from
scratch so to speak.
--
Regards,
Tom Ogilvy
"Phillo" wrote in message
...
Hi, I am trying to use the VBA code given on the Microsoft website at
http://office.microsoft.com/en-us/as...982701033.aspx but
cannot
get the code to work after several attempts. Does anybody else have any
idea
on the code to use in Excel 2000 ?