problems with a localconnection to a cub file

P

pimlico

I have tried nearly all combinations I can find of the following.
Totally stuck now. I am on excel 2K.

Set PC = ActiveWorkbook.PivotCaches.Add(xlExternal)
With PC
.LocalConnection = "OLEDB;Provider=MSOLAP;Data
Source=C:\somefilename.cub"
End With

PC.UseLocalConnection = True


It always fails on the uselocalconnection line. I get an error 1004,
app defined or object defined error.

All i want to do is open a local cub file and it doesnt seem to work.

I notice also that the
'MsgBox (ActiveWorkbook.PivotCaches.Count)

gives a value of zero even after the add.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top