DxComboBoxSettings.SearchTextParseMode Property
Specifies how the combo box editor treats search words.
Namespace: DevExpress.Blazor
Assembly: DevExpress.Blazor.v24.2.dll
NuGet Package: DevExpress.Blazor
Declaration
[DefaultValue(ListSearchTextParseMode.Default)]
[Parameter]
public ListSearchTextParseMode SearchTextParseMode { get; set; }
Property Value
Type | Default | Description |
---|---|---|
ListSearchTextParseMode | Default | An enumeration value. |
Available values:
Name | Description |
---|---|
Default | The |
GroupWordsByAnd | The search words are grouped as individual conditions by the |
GroupWordsByOr | The search words are treated as individual conditions grouped by the |
ExactMatch | The search words are not treated separately. Only records that match the search text exactly are shown. |
Remarks
The search feature allows users to locate and highlight the search text in combo box editor data. If the search text contains multiple words separated by space characters, the words can be treated as a single condition or as individual conditions grouped by the Or
or And
operator.
Use the SearchTextParseMode
property to specify how the combo box editor component treats search words.
The following code snippet sets SearchTextParseMode
to ExactMatch
:
<DxGrid Data="Products"
EditMode="GridEditMode.EditRow"
CustomizeEditModel="Grid_CustomizeEditModel"
EditModelSaving="Grid_EditModelSaving">
<Columns>
<DxGridCommandColumn DeleteButtonVisible="false" Width="15%" />
<DxGridDataColumn FieldName="ProductName" Width="25%" />
<DxGridDataColumn FieldName="CategoryId" Caption="Category" Width="10%">
<EditSettings>
<DxComboBoxSettings Data="Categories"
ValueFieldName="CategoryId"
TextFieldName="CategoryName"
SearchTextParseMode="ListSearchTextParseMode.ExactMatch" />
</EditSettings>
</DxGridDataColumn>
<DxGridDataColumn FieldName="UnitPrice" DisplayFormat="c" Width="10%">
<EditSettings>
<DxSpinEditSettings MinValue="0M" Mask="n3" />
</EditSettings>
</DxGridDataColumn>
<DxGridDataColumn FieldName="UnitsInStock" />
<DxGridDataColumn FieldName="QuantityPerUnit" Width="15%" />
<DxGridDataColumn FieldName="Discontinued" />
</Columns>
</DxGrid>