I need to execute the "create global cube" statement to create a cube from existing cube using VBA. ......When i tried to use the execute command , i get parsing error.

Here is the code...

Public Sub ExectueOlapCommand(sConnect As String)
Dim cmd As adodb.Command
Dim sCommand As String
Dim i As Integer

command = "CREATE GLOBAL CUBE [Warehouse1998Local]
STORAGE 'C:\WarehouseLocal.cub'
FROM [Warehouse]
MEASURE [Warehouse].[Store Invoice],
MEASURE [Warehouse].[Supply Time],
MEASURE [Warehouse].[Warehouse Cost],
MEASURE [Warehouse].[Warehouse Sales],
MEASURE [Warehouse].[Units Shipped],
MEASURE [Warehouse].[Units Ordered],
MEASURE [Warehouse].[Warehouse Profit],
DIMENSION [Warehouse].[Store],
DIMENSION [Warehouse].[Store Size in SQFT],
DIMENSION [Warehouse].[Store Type],
DIMENSION [Warehouse].[Time]
LEVEL [Year],
LEVEL [Month],
MEMBER [Time].[1998]
DIMENSION [Warehouse].[Warehouse]

Set cmd = New adodb.Command

cmd.ActiveConnection = omCon
cmd.CommandType = adCmdTable
cmd.CommandText = sCommand


End Sub

Please let me know how to execute Analysis Serivces DDL from Excel/VBA or send me some sample code to execute OLAP DDLs in VBA.