We help IT Professionals succeed at work.

Excel VBA - AutoFilter turn off if on

481 Views
Last Modified: 2017-04-19
I see that AutoFilter is a toggle.
ie. Selection.AutoFilter

I have range where there are some AutoFilters. I want to turn off AutoFilter only if they are On.
I don't want to toggle because then I will create an AutoFilter where there is none.

How do I test if AutoFilter exists? I have a range for the Column Headers Range("ColumnHeaders") where the AutoFilters, if any, are.

Thanks
Comment
Watch Question

Managing Director/Excel VBA Developer
CERTIFIED EXPERT
Distinguished Expert 2018
Commented:
This problem has been solved!
(Unlock this solution with a 7-day Free Trial)
UNLOCK SOLUTION
Martin LissProtect yourself and your loved ones. Stay home for the holidays.
CERTIFIED EXPERT
Most Valuable Expert 2017
Distinguished Expert 2018
Commented:
This problem has been solved!
(Unlock this solution with a 7-day Free Trial)
UNLOCK SOLUTION