PivotCache.OptimizeCache 屬性 (Excel)PivotCache.OptimizeCache property (Excel)

True 是表示如果樞紐分析表快取最佳化建構時。True if the PivotTable cache is optimized when it's constructed. 預設值為 FalseThe default value is False. 可讀寫的 BooleanRead/write Boolean.

語法Syntax

運算式OptimizeCacheexpression.OptimizeCache

_運算式_代表**PivotCache** 物件的變數。expression A variable that represents a PivotCache object.

註解Remarks

快取最佳化會產生額外的查詢,而且會降低樞紐分析表的初始效能。Cache optimization results in additional queries and degrades initial performance of the PivotTable report.

就 OLE DB 資料來源而言,這是一個唯讀屬性,而且永遠會傳回 FalseFor OLE DB data sources, this property is read-only and always returns False.

範例Example

本範例會在建構時執行最佳化的第一個工作表上第一個樞紐分析表報告的樞紐分析表快取。This example causes the PivotTable cache for the first PivotTable report on worksheet one to be optimized when it's constructed.

Worksheets(1).PivotTables("Pivot1") _ 
 .PivotCache.OptimizeCache = True

支援和意見反應Support and feedback

有關於 Office VBA 或這份文件的問題或意見反應嗎?Have questions or feedback about Office VBA or this documentation? 如需取得支援服務並提供意見反應的相關指導,請參閱 Office VBA 支援與意見反應Please see Office VBA support and feedback for guidance about the ways you can receive support and provide feedback.