Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

Clone AutoFilter object in Excel

Posted on 2012-03-21
2
Medium Priority
?
263 Views
Last Modified: 2012-08-13
May I know if it is possible to clone an AutoFilter object in Excel 2010?

My purpose is this:

I have got a number of source data tables in 1 sheet.  I'd like to manipulate the data filtering in the source tables in code, copying the filtered results to other sheets.

At the end, I'd like to restore the AutoFilters originally set in the source tables.

Thanks,
Janice
0
Comment
Question by:janicep
2 Comments
 
LVL 85

Accepted Solution

by:
Rory Archibald earned 1500 total points
ID: 37747248
I can only think of two real options (there is no simple cloning facility, sadly):
1. Copy the sheet and manipulate the copy of it.
2. You would have to loop through all the tables, loop through each filter in the table, check if it's on and if so, store the operator and both criteria values. Then after your manipulation is done, you would need to reverse this process.

option 1 is obviously simpler, if a bit clunky. Would it work for you?
0
 

Author Closing Comment

by:janicep
ID: 37751899
I guess I will need 2.  At least I know I am not going to do something easy in an overly complex way.  Thanks!
0

Featured Post

Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article descibes how to create a connection between Excel and SAP and how to move data from Excel to SAP or the other way around.
You need to know the location of the Office templates folder, so that when you create new templates, they are saved to that location, and thus are available for selection when creating new documents.  The steps to find the Templates folder path are …
This Micro Tutorial will demonstrate how to use longer labels with horizontal bar charts instead of the vertical column chart.
This Micro Tutorial will demonstrate in Microsoft Excel how to add style and sexy appeal to horizontal bar charts.

927 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question