I have 2 sheets where I paste data into daily. I have premade PivotTables (source data is columns A:S).
After I paste my data, I run a macro but noticed the PivotTables don't refresh until I hit the 'Refresh All' button under the Data tab. Is my code missing something?
Application.ScreenUpdating = False
Dim pc As PivotCache
For Each pc In ThisWorkbook.PivotCaches
pc.Refresh
Next pc
ThisWorkbook.RefreshAll
So I thought I need to refresh the PivotCache first of course, and it goes through all PivotCaches, and then RefreshAll to refresh the actual tables.
Not sure what I'm missing. Any help is appreciated, thanks!