PDA

View Full Version : Solved: Pivot help



jmenche
01-30-2013, 12:46 PM
Howdy,

I have a sheet with a few pivottables on it. I have some drop downs up top that allow the user to select two different products and a macro loops through and updates the 'Product' field in each pivot with the user selection.

Here's the issue. What the macro does is make the two new products visible and then hides the two old products. Since you cannot have all items hidden at once, all four items are visible at one point. This causes the pivot rows to expand and contract because the row selections can be different for each product. When the pivot rows expand, it encroaches on the pivottable below it and I get an error. I don't want to leave all kinds of rows blank between them because it looks stupid.

Is there a way to change the products without the pivot updating like that in the interim?

Thanks

Jeff
:beerchug:

p45cal
01-30-2013, 03:48 PM
Yes, set the the pivot table which is likely to encroach on the other's ManualUpdate Property to True before changing anything, make all the Product field changes, then reset the property to False.
You won't be able to step through the code to watch this happening, you'll have to let the code run. Do read the Help on this property.

jmenche
01-30-2013, 04:58 PM
BOOYA!!! I was stuck on this all day

Thanks!!