blazor-devexpress-dot-blazor-dot-dxgrid-0f2cd0f8.md
Specifies whether the Grid displays the search box.
Namespace : DevExpress.Blazor
Assembly : DevExpress.Blazor.v25.2.dll
NuGet Package : DevExpress.Blazor
[DefaultValue(false)]
[Parameter]
public bool ShowSearchBox { get; set; }
| Type | Default | Description |
|---|---|---|
| Boolean | false |
true to display the search box; otherwise, false.
|
The search box allows users to type text in the box editor to filter and highlight data. Set the ShowSearchBox property to true to display the search box.
<DxGrid Data="@Data" ShowSearchBox="true">
<Columns>
<DxGridDataColumn FieldName="ContactName"/>
<DxGridDataColumn FieldName="City"/>
<DxGridDataColumn FieldName="Country"/>
</Columns>
</DxGrid>
You can use the following members to customize the search box.
SearchBoxInputDelaySpecifies the time interval between the last typed character in the search box and the consequent search text update.SearchBoxNullTextSpecifies the prompt text displayed in the search box when it is empty.CustomizeElementAllows you to customize the search box style settings.SearchBoxTemplateAllows you to implement custom content for the search box.SearchTextAllows you to implement an external search box and bind its value to the grid search text.
Users can press Ctrl+F to focus the search box. For additional information about search in the Grid component, refer to the following topic: Search Box in Blazor Grid.
See Also