Updating "pivots"

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

It seams that

ActiveWorkbook.RefreshAll

dos not update pivot tables!

Any hints
 
You sure.

VBA's help does have this remark:

Remarks
Objects that have the BackgroundQuery property set to True are refreshed in the
background.


And if you click on BackgroundQuery, you'll see this sample code:

Worksheets(1).PivotTables("Pivot1") _
.PivotCache.BackgroundQuery = True
 
Hi Jens

Try
Sub RefreshAllPivots()
Dim pc As PivotCache
For Each pc In ActiveWorkbook.PivotCaches
pc.Refresh
Next
End Sub
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top