Problem with autofilter...

jenrique.cerda

Board Regular
Joined
Sep 22, 2006
Messages
53
Hi, is there a way to set autofilter as on or of???

Something like Autofilter=False or true???

Thanks...
 

Excel Facts

Create a Pivot Table on a Map
If your data has zip codes, postal codes, or city names, select the data and use Insert, 3D Map. (Found to right of chart icons).

texasalynn

Well-known Member
Joined
May 19, 2002
Messages
8,458
not really but you could have it turn on/off with the
ActiveCell.Offset(0, 0).Range("A1").AutoFilter
 

jenrique.cerda

Board Regular
Joined
Sep 22, 2006
Messages
53
but how does this works???
does it detects wether if the filter is tunred on or off???

I just need to save af file without the autofilter..... a user may save this file with the autofilter turned on but once i run my routine, there is a part that opens this file and has to save it turned off...
 

Emjaye

Board Regular
Joined
Oct 3, 2003
Messages
89
Hi

You can kinda do it - assuming you cell with the autofilter is applied in is ("E7"), if you activate this line of code

Code:
 Range("e7").AutoFilter Field:=1

perhaps using a workbook or worksheet event, it set the autofilter back to "field 1" which is effectively resetting it.
 

Krishnakumar

Well-known Member
Joined
Feb 28, 2003
Messages
2,615
Hi,

May be something like..

Code:
If ActiveSheet.AutoFilterMode = True Then
    'your code here
Else
    'your code here
End If
 

Forum statistics

Threads
1,140,938
Messages
5,703,278
Members
421,289
Latest member
fbohlandt

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Top