I'm trying to connect to a SSAS Tabular Server instance via code behind. The Statement GenerateInitialDatabase works fine and returns the database. However the GenerateInitialCube methods returns just null. The String for the cube name is correct(screenshot attached from connection to it via excel). Under what circumstances does this method returns null?
AdomdConnectionSettings connectionSettings = new AdomdConnectionSettings(); connectionSettings.ConnectionString = connectionString; ((AdomdDataSource)MyXamPivotGrid.DataSource).ConnectionSettings = connectionSettings; ((AdomdDataSource)MyXamPivotGrid.DataSource).Database = XmlaDataSource.GenerateInitialDatabase("TestDatabase"); MyXamPivotGrid.DataSource.Cube = XmlaDataSource.GenerateInitialCube("Model");
Hello,
Thank you for the post. Looking at the code snippet you provided ,your cube Datasource is XmlaDataSource not AdomdDatasource is this intentional? You are mixing two kind of datasources , as i am not familiar with this scenario.
In our Sample browser we do have sample binding the PivotGrid with AdomdDataSource and XmlaDataSource if you wants to have a look.
SB-> XamPivotGrid-> Data->Adomd.net DataSource and SB-> XamPivotGrid-> Data->XMLAdataSource.
Please let me know if you have any question.
Sincerly,
Divya Jain