View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Jason Jason is offline
external usenet poster
 
Posts: 367
Default Worksheet Activate Event

I have the following code, which is being run when a worksheet called "RV
Summary" is being selected.

Private Sub Worksheet_Activate()

Sheets("Crosstab").Activate
ActiveSheet.PivotTables("PivotTable_Statistics").P ivotCache.Refresh
Sheets("RV Summary").Select

End Sub

Whenever "RV Summary" is selected, I want a pivot table located on another
sheet (Crosstab) to get refreshed, and then I want it to maintain "RV
Summary" as the active sheet (essentially the user will not even know that
this pivot is being updated when they select (RV Summary). The problem is
that this gets into a never ending loop. Is their a way to alter this or
make it so that it only performs this action once and then just goes back to
RV Summary. Thanks.