dashboard-devexpress-dot-dashboardwin-dot-dashboardviewer-ad99489b.md
Gets or sets the currently opened dashboard.
Namespace : DevExpress.DashboardWin
Assembly : DevExpress.Dashboard.v25.2.Win.dll
NuGet Package : DevExpress.Win.Dashboard
[Browsable(false)]
public Dashboard Dashboard { get; set; }
<Browsable(False)>
Public Property Dashboard As Dashboard
| Type | Description |
|---|---|
| Dashboard |
A Dashboard object that is the currently opened dashboard.
|
You can open a dashboard in one of the following ways.
All these actions raise the DashboardViewer.DashboardChanged event.
Note
You cannot use the same instance of the dashboard object in the DashboardDesigner and DashboardViewer controls at the same time. You can use the SaveToXml / LoadFromXml methods to create a copy of the dashboard object.
The following code snippets (auto-collected from DevExpress Examples) contain references to the Dashboard property.
Note
The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.
Dashboard dashboard = new Dashboard(); dashboard.LoadFromXml(@"..\..\Data\Dashboard.xml");
dashboardViewer1.Dashboard = dashboard;
GridDashboardItem grid = (GridDashboardItem)dashboard.Items["gridDashboardItem1"];
winforms-dashboard-create-layout-from-scratch/CS/Dashboard_LayoutCustomization/Form1.cs#L62
dashboardViewer1.Dashboard = dashboard;
}
Dashboard dashboard = new Dashboard(); dashboard.LoadFromXml(@"..\..\Data\Dashboard.xml");
dashboardViewer1.Dashboard = dashboard;
GridDashboardItem grid = (GridDashboardItem)dashboard.Items["gridDashboardItem1"];
dashboard.Items.AddRange(pies, grid);
dashboardViewer1.Dashboard = dashboard;
winforms-dashboard-bind-geo-point-map-to-data-in-code/CS/Dashboard_CreateGeoPointMap/Form1.cs#L29
dashboard.Items.Add(geopointMap);
dashboardViewer1.Dashboard = dashboard;
}
dashboard.LoadFromXml("..\..\Data\Dashboard.xml")
dashboardViewer1.Dashboard = dashboard
Dim grid As GridDashboardItem = CType(dashboard.Items("gridDashboardItem1"), GridDashboardItem)
winforms-dashboard-create-layout-from-scratch/VB/Dashboard_LayoutCustomization/Form1.vb#L50
dashboardViewer1.Dashboard = dashboard
End Sub
dashboard.LoadFromXml("..\..\Data\Dashboard.xml")
dashboardViewer1.Dashboard = dashboard
Dim grid As GridDashboardItem =
dashboard.Items.AddRange(pies, grid)
dashboardViewer1.Dashboard = dashboard
winforms-dashboard-bind-geo-point-map-to-data-in-code/VB/Dashboard_CreateGeoPointMap/Form1.vb#L30
dashboard.Items.Add(geopointMap)
dashboardViewer1.Dashboard = dashboard
End Sub
See Also