Skip to main content
All docs
V24.1

DxDropDownListEditorBase<TData, TValue>.SearchTextParseMode Property

Specifies how the editor treats search words.

Namespace: DevExpress.Blazor.Base

Assembly: DevExpress.Blazor.v24.1.dll

NuGet Package: DevExpress.Blazor

Declaration

[DefaultValue(ListSearchTextParseMode.Default)]
[Parameter]
public ListSearchTextParseMode SearchTextParseMode { get; set; }

Property Value

Type Default Description
ListSearchTextParseMode Default

The text parse mode.

Available values:

Name Description
Default

The ExactMatch is used by default. The search words are not treated separately. Only records that match the search text exactly are shown.

GroupWordsByAnd

The search words are grouped as individual conditions by the AND logical operator. Only records that match all the conditions are shown.

GroupWordsByOr

The search words are treated as individual conditions grouped by the OR logical operator. Records that match at least one of these conditions are shown.

ExactMatch

The search words are not treated separately. Only records that match the search text exactly are shown.

Remarks

The DevExpress Blazor ComboBo and TagBox components can search for text, and filter and highlight search results. Use the following API members to enable search and filter capabilities:

  • SearchMode — Specifies whether the component can search for text that users type in the edit box. When the AutoSearch mode is active, the ComboBox filters its items based on the search string and highlights string matches. All visible columns take part in search operations.

    Users can use special characters to create composite criteria. Refer to the following section for additional information: Search Syntax.

  • SearchFilterCondition — Specifies the search and filter condition (Contains, Equals, or StartsWith).
  • SearchTextParseMode — Specifies how the component combines words into the search query. If search text contains multiple words separated by space characters, words can be treated as a single condition or individual conditions. The following modes are available: GroupWordsByAnd, GroupWordsByOr, and ExactMatch.
  • SearchEnabled - Specifies whether the component can search text in cells of the current column.

ComboBox Example

<DxComboBox Data="Staff.DataSource" 
            @bind-Value="@Value" 
            SearchMode="ListSearchMode.AutoSearch"
            SearchFilterCondition="ListSearchFilterCondition.Contains">
    <Columns>
        <DxListEditorColumn FieldName="FirstName"></DxListEditorColumn>
        <DxListEditorColumn FieldName="LastName"></DxListEditorColumn>
        <DxListEditorColumn FieldName="Department" SearchEnabled="false"></DxListEditorColumn>
    </Columns>
</DxComboBox>

@code {
    string Value { get; set; }
}

When a user types text into the edit box, the ComboBox filters and highlights search results.

ComboBox - Filter Data

Run Demo: ComboBox - Search and Filter Data

Implements

DevExpress.Blazor.IDropDownListEditorBase<TData, TValue>.SearchTextParseMode
See Also