DashboardDesigner.UpdateDashboardTitle() Method
Fires the CustomizeDashboardTitle event that allows you to customize the dashboard title content.
Namespace: DevExpress.DashboardWin
Assembly: DevExpress.Dashboard.v24.2.Win.dll
Declaration
Example
The following code snippets demonstrate how to load data in the Dashboard designer on demand when all required filters are set. For this, the Show Data button is created in the DashboardDesigner.CustomizeDashboardTitle event handler.
using DevExpress.DashboardWin;
using System;
using System.Linq;
namespace CustomShowDataExample
{
public partial class DesignerForm1 : DevExpress.XtraBars.Ribbon.RibbonForm
{
public DesignerForm1()
{
InitializeComponent();
dashboardDesigner.CustomizeDashboardTitle += DashboardDesigner_CustomizeDashboardTitle;
dashboardDesigner.LoadDashboard(@"..\..\Dashboards\dashboard1.xml");
}
#region #CustomizeDashboardTitle
private void DashboardDesigner_CustomizeDashboardTitle(object sender, CustomizeDashboardTitleEventArgs e)
{
DevExpress.Data.IParameter showDataParameter = dashboardDesigner.Parameters.FirstOrDefault(p => p.Name == "ShowData");
if (showDataParameter != null)
{
bool showData = (bool)showDataParameter.Value;
DashboardToolbarItem showDataItem = new DashboardToolbarItem(showData, "Select states in the State list box and click this button to display data",
new Action<DashboardToolbarItemClickEventArgs>((args) => {
showDataParameter.Value = !showData;
}));
showDataItem.Caption = "Show Data";
showDataItem.SvgImage = svgImageCollection1[0];
e.Items.Insert(0, showDataItem);
}
}
#endregion #CustomizeDashboardTitle
}
}
Related GitHub Examples
The following code snippets (auto-collected from DevExpress Examples) contain references to the UpdateDashboardTitle() method.
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.