View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Kyle[_3_] Kyle[_3_] is offline
external usenet poster
 
Posts: 1
Default Name of Event for Sheet

I'm attempting to write code that hides the PivotTable
Field List when a Pivot Table is either created or
updated, but I haven't found an event that will trigger
the code. What I have written will hide the list when a
new sheet is created, but doesn't do anything when you
create or modify the table on a current sheet. Can anyone
help me find an event to trigger this code?

This is what I have in a Class Module:

Private Sub App_SheetActivate(ByVal Sh As Object)
'Don't show Pivot Table Field List when creating a Pivot
Table

Dim wkbOne As Workbook

Set wkbOne = Application.ActiveWorkbook

'Determine PivotTable field list setting.
If wkbOne.ShowPivotTableFieldList = True Then
wkbOne.ShowPivotTableFieldList = False
End If

End Sub