Version Information
Version Added: Excel

Syntax

expression.UseLocalConnection

expression A variable that represents an OLEDBConnection object.

Remarks

This example sets the connection string of the first PivotTable cache to reference an offline cube file.

Example

Visual Basic for Applications
With ActiveWorkbook.PivotCaches(1) .LocalConnection = _ "OLEDB;Provider=MSOLAP;Data Source=C:\Data\DataCube.cub" .UseLocalConnection = True End With 

See also: