aspnet-devexpress-dot-web-dot-aspxautocompleteboxbase-1a6a16be.md
Specifies the incremental filter mode.
Namespace : DevExpress.Web
Assembly : DevExpress.Web.v25.2.dll
NuGet Package : DevExpress.Web
[DefaultValue(IncrementalFilteringMode.Contains)]
public virtual IncrementalFilteringMode IncrementalFilteringMode { get; set; }
<DefaultValue(IncrementalFilteringMode.Contains)>
Public Overridable Property IncrementalFilteringMode As IncrementalFilteringMode
| Type | Default | Description |
|---|---|---|
| IncrementalFilteringMode | Contains |
A value of the enumeration.
|
Available values:
| Name | Description |
|---|---|
| Contains |
The editor filters items that contain the filter string.
| | StartsWith |
The editor filters items that begin with the filter string.
| | None |
The editor does not filter items.
|
The editor can filter items on the client while a user types the filter string. Use the IncrementalFilteringMode property to specify the editor’s filter mode.
IncrementalFilteringMode=”Contains”
IncrementalFilteringMode=”StartsWith”
The editor can use callbacks in incremental filter mode.
In markup:
<dx:ASPxComboBox ID="Countries" runat="server" EnableCallbackMode="True" IncrementalFilteringMode="StartsWith">
<Items>
<!--...-->
</Items>
</dx:ASPxComboBox>
In code:
protected void Page_Load(object sender, EventArgs e){
ASPxComboBox cb = new ASPxComboBox();
cb.Items.AddRange(new List<ListEditItem>(){
//...
})
cb.EnableCallbackMode = true;
cb.IncrementalFilteringMode = IncrementalFilteringMode.StartsWith;
}
In incremental filtering mode, the ASPxComboBox can filter its items according to the format specified in the ASPxAutoCompleteBoxBase.TextFormatString property.
<dx:ASPxComboBox ID="ASPxComboBox1" runat="server" DataSourceID="EmployeesDataSource" ValueField="EmployeeID"
DropDownStyle="DropDown" TextFormatString="{0} from {2}" IncrementalFilteringMode="Contains">
<Columns>
<dx:ListBoxColumn FieldName="FirstName" />
<dx:ListBoxColumn FieldName="LastName" />
<dx:ListBoxColumn FieldName="City" />
</Columns>
</dx:ASPxComboBox>
<ef:EntityDataSource runat="server" ID="EmployeesDataSource" .../>
Run Demo: ASPxComboBox - Incremental Filtering
See Also