Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.misc
|
|||
|
|||
Macro / Autofilter / Show All Data
Hi,
I wrote in the macro ActiveSheet.ShowAllData but if no filtering is set, I get error message. Is it possible to say something like If 'filtered...' Thanks and regards, Cousin Excel |
#2
Posted to microsoft.public.excel.misc
|
|||
|
|||
Macro / Autofilter / Show All Data
The easiest way will be by adding:
On Error resume Next as the first command of the macro. Micky "CousinExcel" wrote: Hi, I wrote in the macro ActiveSheet.ShowAllData but if no filtering is set, I get error message. Is it possible to say something like If 'filtered...' Thanks and regards, Cousin Excel |
#3
Posted to microsoft.public.excel.misc
|
|||
|
|||
Macro / Autofilter / Show All Data
As On error may cause some other "problems" - try this:
If ActiveSheet.FilterMode Then ActiveSheet.ShowAllData Micky "מיכאל (מיקי) אבידן" wrote: The easiest way will be by adding: On Error resume Next as the first command of the macro. Micky "CousinExcel" wrote: Hi, I wrote in the macro ActiveSheet.ShowAllData but if no filtering is set, I get error message. Is it possible to say something like If 'filtered...' Thanks and regards, Cousin Excel |
#4
Posted to microsoft.public.excel.misc
|
|||
|
|||
Macro / Autofilter / Show All Data
If you want to remove the filter (and filter arrows):
With worksheets("Somesheetnamehere") .autofiltermode = false end with If you want to just show the data, but keep the arrows: With worksheets("Somesheetnamehere") if .filtermode then 'some filter is applied .showalldata end if end with CousinExcel wrote: Hi, I wrote in the macro ActiveSheet.ShowAllData but if no filtering is set, I get error message. Is it possible to say something like If 'filtered...' Thanks and regards, Cousin Excel -- Dave Peterson |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Macro - filter - show all data | Excel Worksheet Functions | |||
autofilter show all data | Excel Discussion (Misc queries) | |||
How can i Change Autofilter data from top till bottom in macro | Excel Discussion (Misc queries) | |||
Autofilter- show dates differently | Excel Discussion (Misc queries) | |||
Why does AutoFilter not show all the data in the pull down? | Excel Discussion (Misc queries) |