I have a pivot table (image below) with three row fields. I would like to select a data range using the value of the second row field, and then format the selected range based on that value. The problem is when I iterate through the pivot items in the second row field, my code lists all the items in the field, not the one item associated with rowfield (1) value. I can't seem to search based on a hierarchy like this:
for each item in rowfield(1)
if rowfield(2).pivotitem value = "x" then
select and format for x
leave format alone
Using an index to the pivot items of rowfield two doesn't return only the item for that field, it returns all values in the domain for the field. I'd like to base the action on the value of the item in the second row field, but I can't seem to query the value of that item alone.