I'm trying to use VBA to extract and manipulate data from a pivot table. My pivot table has three Row labels (D_Campaign, D_TL, D_Agent_Name).
Using
For Each pt1 In pt.RowFields("D_Agent_Name").PivotItems
Debug.Print pt1.Name
Next pt1
I can get a list of all the labels in 'D_Agent_Name'. However, what I would like, is a list of the labels in 'D_Agent_Name' for a given value of 'D_TL'. Can anyone point me in the right direction?