TreeListOptionsFilter.FilterMode Property
Gets or sets whether to show only the filtered nodes or also show their parent and child nodes. Additionally, you can enable the ExpandNodesOnFiltering property to automatically expand filtered nodes.
Namespace: DevExpress.XtraTreeList
Assembly: DevExpress.XtraTreeList.v19.2.dll
Declaration
[DefaultValue(FilterMode.Default)]
[XtraSerializableProperty]
public virtual FilterMode FilterMode { get; set; }
Property Value
Type | Default | Description |
---|---|---|
FilterMode | **Default** | A FilterMode enumeration value that specifies how filtered nodes are shown. |
Available values:
Name | Description |
---|---|
Default | Equivalent to ‘ParentBranch’ mode for the TreeList control. Equivalent to ‘Matches’ mode for the TreeListLookUpEdit control. |
ParentsMatch | Shows nodes if they and all their parents match the filter. If a node fits the filter but any of its parents does not, the node is not displayed. |
Matches | Shows only those nodes that match the filter. |
ParentBranch | Shows nodes that match the filter along with the nodes’ parents (even if they do not fit the filter). |
EntireBranch | Shows nodes that match the filter along with the nodes’ parents and children (even if they do not fit the filter). |
Standard | The same as the ‘ParentsMatch’ option. |
Smart | The same as the ‘Matches’ option. |
Extended | The same as the ‘ParentBranch’ option. |
Property Paths
You can access this nested property as listed below:
Library | Object Type | Path to FilterMode |
---|---|---|
WinForms Controls | GanttControl |
|
ResourcesTree |
|
|
TreeList |
|
|
Reporting | XRDesignFieldList |
|
XRDesignReportExplorer |
|
Remarks
This property specifies whether to show only the filtered nodes or also show the parent and child nodes. You can also hide nodes that have parent nodes that do not match the filter criteria. See FilterMode for more information.
Note
Use the following properties to allow users to filter nodes:
- for version 17.1, use the TreeList.OptionsCustomization.AllowFilter property
- for older versions, use the TreeList.OptionsBehavior.EnableFiltering property
For more information, see Version Compatibility: Default Property Values.
Related GitHub Examples
The following code snippets (auto-collected from DevExpress Examples) contain references to the FilterMode 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.