This is the core:
Sub RefreshPivots()
Dim ws As Worksheet
Dim pt As PivotTable
For Each ws In ActiveWorkbook.Worksheets
For Each pt In ws.PivotTables
pt.PivotCache.Refresh
Next pt
Next ws
End Sub
It could be changed:
perhaps triggered via workbook-level worksheet pivot table update event
depending on location, 'activeworkbook' could be changed to 'me' or removed altogether
It has taken a while to get a reply because you've posted in a forum on worksheet functions. If you are more careful with which forum your thread belongs in, you will get a better response.
CC
Bookmarks