Pivot Table - Trigger event on drill down

Pivot Table - Trigger event on drill down

Post by TWFydHluIF » Sun, 07 Aug 2005 00:15:37


Is it possible to trigger an event on vba when a user drills down (or back)
in a pivot table. Is there anything like: ?

sub PivotTable.OnDrillDown

End Sub

Thanks
 
 
 

Pivot Table - Trigger event on drill down

Post by Tom Ogilv » Sun, 07 Aug 2005 00:35:42

You can use the workbook newsheet event in xl97 and later. Just check each
new sheet and determine if it appears to be produced from a pivot table
drilldown. I am not familiar with a drill back.

--
Regards,
Tom Ogilvy



back)

 
 
 

Pivot Table - Trigger event on drill down

Post by TUlLRTIxN » Sun, 07 Aug 2005 01:53:06

Hi Martyn,

So far as I know, there are know pivot table events. The worksheet
calculate event fires when the pivot table changes as a result of a drill up
or down. Depending on your purpose that might make a good substitue.

Regards,
Mike
 
 
 

Pivot Table - Trigger event on drill down

Post by TWFydHl » Wed, 10 Aug 2005 00:57:21

Thanks for that, "Worksheet_Calculate" worked just how id hoped. My drill
down/up is the type where the pivot table expands rather that generates a new
sheet, so the calculate solution is the best to use for now. Thanks also to
Tom as the new sheet event will probably come in handy sooner or later.

:)

Martyn