Is there a way I can check to see if a pivot item exists in a particular pivot field by using vba?
I have a pivot table that has all of the sales data for the sales reps in my company. I can automatically change the name of the rep in the pivot table by changing the value in an adjacent cell by using a worksheet change event. I ran into a problem when a new sales rep started and he had not made a sale yet. I have been trying to find a way to test to see if the pivot item, the sales rep name, exists before the pivot table updates. If the pivot item does not exist the pivot table should hide all of the values in the Pivot Field.
Any ideas? Thanks
I have a pivot table that has all of the sales data for the sales reps in my company. I can automatically change the name of the rep in the pivot table by changing the value in an adjacent cell by using a worksheet change event. I ran into a problem when a new sales rep started and he had not made a sale yet. I have been trying to find a way to test to see if the pivot item, the sales rep name, exists before the pivot table updates. If the pivot item does not exist the pivot table should hide all of the values in the Pivot Field.
Any ideas? Thanks