ASPxFilterControlBase.ApplyFilter() Method
Applies a filter constructed by an end-user.
Namespace: DevExpress.Web
Assembly: DevExpress.Web.v24.2.dll
NuGet Package: DevExpress.Web
#Declaration
#Remarks
The ASPxFilterControl is a stand-alone control that allows end-users to build filter criteria of any complexity. The current filter expression can be obtained using the ASPxFilterControlBase.FilterExpression property. After the filter expression has been constructed, you can apply it. To do this, call the ApplyFilter method. After the filter expression has been applied, you can obtain it using the ASPxFilterControlBase.AppliedFilterExpression property and apply to a source control.
protected void ASPxGridView1_CustomCallback(object sender,
DevExpress.Web.ASPxGridViewCustomCallbackEventArgs e) {
ASPxFilterControl1.ApplyFilter();
ASPxGridView1.FilterExpression = ASPxFilterControl1.AppliedFilterExpression;
}
To reset the current filter expression to a previously applied filter expression, use the ASPxFilterControlBase.ResetFilter method. In this instance, the ASPxFilterControlBase.FilterExpression property is set to the ASPxFilterControlBase.AppliedFilterExpression property’s value.