Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations biv343 on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to clean up PivotCache in a workbook?

Status
Not open for further replies.

feipezi

IS-IT--Management
Aug 10, 2006
316
US
Hi,

I was trying to clean up PC in a workbook by the following code but it doesn't seem to work. Did I do anything wrong?

Please advise.

Thanks in advance.


Sub CleanMyPivots()
Dim pc As PivotCache
For Each pc In ActiveWorkbook.PivotCaches
pc.MissingItemsLimit = xlMissingItemsNone
pc.Refresh
Next
End Sub
 
Hi,

Why do you say, "it doesn't seem to work?"

Skip,

[glasses]Just traded in my OLD subtlety...
for a NUance![tongue]
 
Hi,

Because as I checked PivotCache Index, there is no change but the size of the file was getting smaller. That's why I said "it doesn't seem to work".

Thanks.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top