How to: Combine Multiple Dashboards into a Dashboard with Multiple Tab Pages
2 min to read
This example creates a single merged dashboard from multiple individual dashboards, inserting them as tab pages in a tab container.
To insert a dashboard as a tab page contained in another dashboard, the application should perform the following actions in code:
Load the specified dashboard and check whether it has a tab container.
Copy dashboard data sources and resolve name conflicts. Create a dictionary containing old and new names.
Copy dashboard groups and resolve name conflicts. Create a dictionary containing old and new names.
Copy dashboard items except groups and resolve name conflicts. Create a dictionary containing old and new names. Update data bindings using the data source names dictionary created while resolving the data source name conflicts.
Update the layout. Move the layout root to the tab page as a child node. Item and group names specified as source items for the layout items should be updated if they are changed while resolving name conflicts.
In a merged dashboard, you can clean up the data source collection by discovering identical data sources with different names and using the Data Source Browser command button to switch the data source for the selected dashboard item: