This example illustrates how to add a search box to the field list control.
Our PivotExcelFieldListControl uses the TreeViewFieldsPresenter component to show fields in a tree-like view. In this example, we create a TreeViewFieldsPresenter control descendant and implement the filtering functionality at its level. The default TreeViewFieldsPresenter is replaced with our descendant via styles.
Important: The provided approach works when fields are grouped via User Folders. In OLAP mode, fields are grouped automatically. If fields are not grouped, PivotGrid uses another control (not TreeViewFieldsPresenter ) to manage hidden fields and custom style is not used.
Question Comments
Added By: Constant (DevExpress Support) at: 10/9/2015 2:42:04 AM This solution works for the grouped field list. In the OLAP mode, fields are grouped in the customization form by default. In the traditional binding mode, it is possible to group fields manually by specifying the PivotGridField.DisplayFolder Property for all or just some of them. This solution also helps to simplify layout customization if a lot of fields are available.