This example shows how to manage the dashboard state to save and restore selected master filter values, current drill-down levels and other selections such as the selected Choropleth Map's layer.
The saved dashboard state contains the following settings:
- The ChoroplethMap's LayerIndex is set to 1.
- The ChoroplethMap's Master-Filter value is set to Wyoming.
- The Grid's Drill-Down value is set to Bikes.
When the dashboard is closed, the DashboardDesigner.GetDashboardState method obtains a dashboard state object. It is serialized to XML and added to the XElement object stored in the CustomProperties collection. Subsequently, the dashboard with the dashboard state data is saved to the dashboard xml file.
When the application starts, the DashboardDesigner loads the dashboard and the DashboardState object is deserialized and restored using the GetDataFromString method in the DashboardDesigner.SetInitialDashboardState event.
- Manage Dashboard State
- SetInitialDashboardState
- GetDashboardState()
- SetDashboardState(DashboardState)
- DashboardStateChanged
- Dashboard for WinForms - How to Save and Restore the Dashboard State
- Dashboard for WinForms - How to Set the Initial Dashboard State in the Viewer
- Dashboard for WPF - How to Set the Initial Dashboard State
(you will be redirected to DevExpress.com to submit your response)