Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2
Default Copy Pivot Table Data and Paste into New File

I have a spreadsheet with a pivot table, the table basically lists orders
placed by customers. What I need to do is filter the pivot table so that
only orders for a particular customer shows i.e untick "show all" and only
select the customer I wish to view, then copy the data and insert/paste it
into a new excel file. This process then needs to be repeated for each
customer in the filter list.

I have managed to do the above using a macro, however the filter list that
shows the customer names will change often so the macro is only of any use if
the customers never change, so what I need is a script that can do all of the
above but also go through the filter list from start to end regardless of how
many entries there may be or if they have changed.

Can anyone help me? I can supply the excel file and/or screenshots.

Thank you.
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default Copy Pivot Table Data and Paste into New File

To loop throught the list of customers use something like
for each itm in
activesheet.PivotTables(1).PivotFields("Customer") .PivotItems



Next

See Debra Dalgleish's site for hints on working with Pivot Tables, including
using code.

http://www.contextures.com/tiptech.html

--
Regards,
Tom Ogilvy



"S Sainsbury" wrote in message
...
I have a spreadsheet with a pivot table, the table basically lists orders
placed by customers. What I need to do is filter the pivot table so that
only orders for a particular customer shows i.e untick "show all" and only
select the customer I wish to view, then copy the data and insert/paste it
into a new excel file. This process then needs to be repeated for each
customer in the filter list.

I have managed to do the above using a macro, however the filter list that
shows the customer names will change often so the macro is only of any use

if
the customers never change, so what I need is a script that can do all of

the
above but also go through the filter list from start to end regardless of

how
many entries there may be or if they have changed.

Can anyone help me? I can supply the excel file and/or screenshots.

Thank you.



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
any way to copy and paste values from pivot table and keepformatting? eggman2001 Excel Discussion (Misc queries) 4 April 8th 08 05:07 PM
Printing pivot table along with a copy and paste for each page fie Jennifer Excel Discussion (Misc queries) 1 December 3rd 07 12:29 PM
Pivot table copy and paste yllee70 Excel Worksheet Functions 0 February 23rd 05 07:39 AM
copy/paste pivot table Todd L. Excel Worksheet Functions 0 December 30th 04 04:11 PM
Pivot Table Copy Paste Matthew Davis Excel Programming 1 November 10th 03 09:25 AM


All times are GMT +1. The time now is 10:16 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"