Pivot Page field filter based on cell value

  • Thread starter Thread starter michel.wielens
  • Start date Start date
M

michel.wielens

Hi, I am new in VBA and I have created a code that gets information
from an access query and set up a pivot table. The worksheet contains
multiple pivottables. All pivot tables have at least one page field
(product). The worksheet should be copied and then every pivot on the
active sheet should be filtered on one product (example: worksheet for
milk, worksheet for cheese, worksheet for etc). This for every product
(couple op 30-35 products).

How can I copy the 'mastersheet' (named ' Master') and filter all
pivot tables for a specific Page field product?
 
Hi,

Select the pivot table and choose the command PivotTable, Show Pages, pick
the product field if necessary and click OK
 
Great! Never knew of this option! However, their are multiple pivot
tables on one page, and know he only set up new sheets for the
selected pivot table (obvious). I would like to select all pivot
tables on the sheet and run this command. This requires vba I think?
 
Hi,

And, when you run it for one pivot table it generates say 10 new sheets.
Then when you run if for another pivot table it generates another 10 new
sheets. It doesn't put the second set on the sheets with the first set.
 
Back
Top