Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Thanks!
-----Original Message----- If ActiveSheet.AutofilterMode then Activesheet.AutofilterMode = False End if However, this does not cause an error if the autofilter is not on, so you might just execut it without checking Activesheet.Autofiltermode = False -- Regards, Tom Ogilvy "Howard Brody" wrote in message ... I am trying to set criteria in a macro can't find the correct syntax. I want the macro to see if the AutoFilter is active and run code to turn it off if it is. "If Selection.AutoFilter = True" works if an item has been selected in the AutoFilter but not if it's on with nothing selected yet. "Selection.AutoFilter" looks like it resets the AutoFilter, keeping it on but removing any specific selections. How can I check if it's active (whether or not specific criteria has been selected) and turn it completely off if it is? Any help would be greatly appreciated. Thanks in advance! Howard Brody . |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Excel vba autofilter code | Excel Discussion (Misc queries) | |||
Excel VBA AutoFilter code | Excel Discussion (Misc queries) | |||
vba code on autofilter | Excel Discussion (Misc queries) | |||
Autofilter code | Excel Discussion (Misc queries) | |||
VBA code to locate cell address of AutoFilter dropdown box | Excel Discussion (Misc queries) |