dashboard-devexpress-dot-dashboardwpf-dot-dashboardcontrol-8cd7d118.md
Occurs when an end-user changes the state of the master filter.
Namespace : DevExpress.DashboardWpf
Assembly : DevExpress.Dashboard.v25.2.Wpf.dll
NuGet Package : DevExpress.Wpf.Dashboard
public event MasterFilterSetEventHandler MasterFilterSet
Public Event MasterFilterSet As MasterFilterSetEventHandler
The MasterFilterSet event's data class is MasterFilterSetEventArgs. The following properties provide information specific to this event:
| Property | Description |
|---|---|
| DashboardItemName | Gets the name of the dashboard item. |
| SelectedRange | Gets the selected range in the Range Filter dashboard item. |
| SelectedValues | Gets currently selected records in the master filter item. |
The event data class exposes the following methods:
| Method | Description |
|---|---|
| IsNullValue(Object) | Returns whether the specified value is DashboardSpecialValues.NullValue. |
| IsOthersValue(Object) | Returns whether the specified value is DashboardSpecialValues.OthersValue. |
The MasterFilterSet event is raised when an end-user changes the state of the master filter.
The MasterFilterSetEventArgs class exposes the MasterFilterSetEventArgs.DashboardItemName property that allows you to determine the name of the master filter item which causes the event.
Use the MasterFilterSetEventArgs.SelectedValues property to obtain values of currently selected elements in the master filter item. To determine the selected range in the Range Filter dashboard item, use the MasterFilterSetEventArgs.SelectedRange property.
The example demonstrates how to synchronize Master Filter and Drill-Down actions between different dashboards:
View Example: How to Synchronize Master Filter and Drill Down Actions Between Dashboards
Note
The MasterFilterSetEventArgs.SelectedValues property returns the DashboardSpecialValues.NullValue or DashboardSpecialValues.OthersValue values instead of null or “Others” values, respectively.
The following code snippets (auto-collected from DevExpress Examples) contain references to the MasterFilterSet event.
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.
wpf-dashboard-linked-interactivity/CS/WpfDashboard_LinkedInteractivity/ChildWindow.xaml.cs#L26
DashboardControl dParentControl = this.dControl;
dParentControl.MasterFilterSet += DControl_MasterFilterSet;
dParentControl.MasterFilterCleared += DControl_MasterFilterCleared;
wpf-dashboard-how-to-embed-devexpress-control/CS/GanttSample/GanttViewModel.cs#L37
};
dashboardControl.MasterFilterSet += (s, e) => {
updateGantt.Invoke();
wpf-dashboard-linked-interactivity/VB/WpfDashboard_LinkedInteractivity/ChildWindow.xaml.vb#L24
Dim dParentControl As DashboardControl = Me.dControl
AddHandler dParentControl.MasterFilterSet, AddressOf DControl_MasterFilterSet
AddHandler dParentControl.MasterFilterCleared, AddressOf DControl_MasterFilterCleared
wpf-dashboard-how-to-embed-devexpress-control/VB/GanttSample/GanttViewModel.vb#L47
End Sub
AddHandler dashboardControl.MasterFilterSet, Sub(s, e)
updateGantt.Invoke()
See Also