Hi,
if You want to list the cubes from a specific OLAP-DB here it is:
Dim Cat As New ADOMD.Catalog
Dim Conn As New ADODB.Connection
Dim Cub As ADOMD.CubeDef
Conn.Open "Provider=MSOLAP;Data Source=MyServer;Initial Catalog=MyDatabase;"
Set Cat.ActiveConnection = Conn
For Each Cube In Cat.CubeDefs
MsgBox Cube.Name 'name of the cube
'here code to fill listview
Next
Set Cat = Nothing
Conn.Close
Set Conn = Nothing
If You want all cubes from all OLAP-DBs this may be a first try:
Dim DB As DSO.MDStore
For Each DB In dsoServer.MDStores
' DB.Name for every OLAP-DB
For Each Cub In DB.MDStores
' here the Code for list the Cubes (cub.Name)
next Cub
next DB
greets
Bernhard
--
CS Result GmbH
Bischof-von-Henle-Str. 2
93051 Regensburg
"mahajan.arvind (AT) gmail (DOT) com" wrote:
Quote:
I want to know, How to get the list of Cube (Analysis Server's)
Databases Using VB/VBA with ADODB & ADOMD. |