Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Pivot Values
Can anyone assist me in finding the value of a pivot table field?
I have the following code which cycles through my states, but I want to get the value associated with each one: With Activesheet.PivotTables(1).PivotFields("STATE") For i = 1 to .PivotItems.Count temp = .PivotItems(i) Next i End With I would like something exactly like GETPIVOTDATA, but it doesn't seem to be available in VBA. I have played with grabbing the value from the appropriate cell on the sheet, but if you change the layout this fails. I have also played with setting a cell with the GETPIVOTDATA function and taking the data from that cell, but it seems there has to be a simple code to get the value of an item in a pivot. Thanks, --bnpatten |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Paste values only from a pivot but keep the pivot design when pas. | Excel Worksheet Functions | |||
Copying values from pivot table to cells outside pivot table | Excel Discussion (Misc queries) | |||
Conditional Formatting in Pivot Based on other values in pivot. XL | Excel Discussion (Misc queries) | |||
Using Pivot Table Values | Excel Discussion (Misc queries) | |||
pivot zero values | Excel Worksheet Functions |