PDA

View Full Version : VBA Pivot Table Help



hansonca1
11-14-2011, 11:00 AM
Hello All
Desperately need your help!!

I am trying to get a VBA code which will take data from a pivot table and put this into a new table.

The problem is the cell each week changes due to the data inputted into the Pivot Table. How can I create a VBA code that will pick up the desired cell each time even if this is in a different place.

Is there a way of coding this?

Thanks for your help in advance.

Regards

mdmackillop
11-14-2011, 12:38 PM
Welcome to VBAX
Your question is too vague. You can post a sample using Manage Updates in the Go Advanced reply section and clarify your requirements.

hansonca1
11-15-2011, 04:18 AM
Hello.

As you can see from an attached simplified example.

I am trying to create a VBA code that will extract certain information from a pivot table and put this into a table on another sheet.

In the simplified example I am trying to get all the Male (M) entries in the pivot table into a table titled 'Male Table' How do I go about doing this...?

I also have a problem as when the pivot table gets updated with more data, the number of Males entries will go up etc, and therefore data will be in different cells compared to the previous week. So I need the coding to pick up all male entries within the pivot table, regardless of their cell reference, and copy the data across into the 'male Table'

Please advise as I have been struggling with this for some time now.
Thanks for your help in advance

Regards

Carl

Aflatoon
11-15-2011, 06:31 AM
Cross-posted here (http://www.ozgrid.com/forum/showthread.php?t=160014).