expression.OLAP
expression Required. An expression that returns a PivotCache object.
Example
This example determines if the cache connection is to an OLAP server or not. The example assumes a PivotTable exists on the active worksheet.
Sub CheckPivotCache()
' Determine if PivotCache has OLAP connection.
If Application.ActiveWorkbook.PivotCaches.Item(1).OLAP = True Then
MsgBox "The PivotCache is connected to an OLAP server"
Else
MsgBox "The PivotCache is not connected to an OLAP server."
End If
End Sub