text 如何检查我的工作簿中是否有不同的数据透视缓存?

Posted

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了text 如何检查我的工作簿中是否有不同的数据透视缓存?相关的知识,希望对你有一定的参考价值。

Sub CountWbkCachesAndShowWbkSize()

Dim PC As PivotCache
'~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
If ActiveWorkbook.PivotCaches.Count = 0 Then
    MsgBox "The current workbook has 0 caches"
    
    Else
    
    'counts the number of PivotCaches
    MsgBox "The current workbook has " & ActiveWorkbook.PivotCaches.Count & " caches" _
            & vbNewLine _
 & "The current workbook size is " & Round(FileLen(ActiveWorkbook.FullName) / 1048576, 2) & " MB"
    

End If

End Sub

以上是关于text 如何检查我的工作簿中是否有不同的数据透视缓存?的主要内容,如果未能解决你的问题,请参考以下文章