GridControl.FilterExpression Property
Gets or sets the grid filter expression.
Namespace: DevExpress.Mobile.DataGrid
Assembly: DevExpress.Mobile.Grid.v18.2.dll
Declaration
Property Value
Type | Description |
---|---|
CriteriaOperator | A CriteriaOperator descendant which specifies filter criteria. |
Remarks
Important
This documentation topic describes legacy technology. We no longer develop new functionality for the GridControl and suggest that you use the new DataGridView control instead.
A filter applied to data in the grid is composed of the following criteria.
Column Auto Filters
End-users can apply auto filters to individual columns using the auto-filter panel that is displayed under column headers if the GridControl.AutoFilterPanelVisibility property is set to true. To programmatically specify a column auto filter, use the GridColumn.AutoFilterValue property. The type of comparison operator used to create filter conditions for a column is specified by the GridColumn.AutoFilterCondition property.
Grid Filter Expression
A grid filter expression is specified via the FilterExpression or GridControl.FilterString property. This expression can consist of multiple conditions applied to multiple columns.
To get a string that specifies a filter currently used in the grid, use the GridControl.ActualFilterString property. By default, this string is shown in the filter panel that is automatically displayed at the bottom of the grid after a filter has been created. This panel provides buttons allowing end-users to disable/enable and clear the filter. To control the visibility of the filter panel, use the GridControl.FilterPanelVisibility property.
To clear the grid’s filter from code, use the GridControl.ClearFilter property.