sjonelunas
New Member
- Joined
- Aug 11, 2008
- Messages
- 28
I'm having some trouble with this one. I have a macro that created a pivot table then runs through pivot field options to copy and paste selected data into other sheets. I'm trying to figure out how to tell the macro that if one of the choices isn't yet a choice in the source data to move on to the next one. I tried:
Instead of moving on to the next line of code it changes the pivot field to read HEV and moves on as if it were real when HEV wasn't really a choice in the drop down box.
Any suggestions? Does this make any sense?
Thanks!
Code:
On Error Resume Next
ActiveSheet.PivotTables("PivotTable7").PivotFields("MRP Code").CurrentPage = _
"HEV"
On Error GoTo 0
Instead of moving on to the next line of code it changes the pivot field to read HEV and moves on as if it were real when HEV wasn't really a choice in the drop down box.
Any suggestions? Does this make any sense?
Thanks!