ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   clearing an advanced filter (https://www.excelbanter.com/excel-programming/392205-clearing-advanced-filter.html)

[email protected]

clearing an advanced filter
 
I'm new to xl programming and need to know how to clear an advanced
filter programatically.


I'm applying a filter within the program to a named range, but I can't
clear the filter and redisplay all the data. If I use
activesheet.showalldata, it works if the range is filtered, but
generates an error if the range is already completely displayed.

Thanks


Jim Rech

clearing an advanced filter
 
If ActiveSheet.FilterMode Then ActiveSheet.ShowAllData

--
Jim
wrote in message
ps.com...
| I'm new to xl programming and need to know how to clear an advanced
| filter programatically.
|
|
| I'm applying a filter within the program to a named range, but I can't
| clear the filter and redisplay all the data. If I use
| activesheet.showalldata, it works if the range is filtered, but
| generates an error if the range is already completely displayed.
|
| Thanks
|



Tom Ogilvy

clearing an advanced filter
 
If activesheet.Filtermode then
activesheet.showalldata
End if

--
Regards,
Tom Ogilvy

" wrote:

I'm new to xl programming and need to know how to clear an advanced
filter programatically.


I'm applying a filter within the program to a named range, but I can't
clear the filter and redisplay all the data. If I use
activesheet.showalldata, it works if the range is filtered, but
generates an error if the range is already completely displayed.

Thanks




All times are GMT +1. The time now is 09:59 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com