The AutoFilter object only exists when the AutoFilter feature is turned on. You can determine whether the Worksheet AutoFilter is active by using the value of the AutoFilterMode property : AutoFilter « Excel « VBA / Excel / Access / Word
The AutoFilter object only exists when the AutoFilter feature is turned on. You can determine whether the Worksheet AutoFilter is active by using the value of the AutoFilterMode property
Sub filter() If ActiveSheet.AutoFilterMode Then
MsgBox "Turned on" End If End Sub