Skip to main content
All docs
V24.1
JS

RichEditBuilder.Search(Action<SearchSettingsBuilder>) Method

Specifies search settings.

Namespace: DevExpress.AspNetCore.RichEdit

Assembly: DevExpress.AspNetCore.RichEdit.v24.1.dll

NuGet Package: DevExpress.AspNetCore.RichEdit

Declaration

public RichEditBuilder Search(
    Action<SearchSettingsBuilder> configure
)

Parameters

Name Type Description
configure Action<SearchSettingsBuilder>

A delegate method that specifies search settings.

Returns

Type Description
RichEditBuilder

A builder for the Rich Text Editor.

Remarks

The search panel and the Find and Replace dialog allow users to locate and modify text in a document opened in the Rich Text Editor. You can filter search results to prevent users from modifying certain document intervals. The example below demonstrates how to exclude intervals that contain fields from search results:

<script>
   function displaySearchResult(subDocument, interval) {
       return subDocument.fields.find(interval).length == 0;
   }
</script>
@(Html.DevExpress().RichEdit("RichEdit")
   .Search(searchSettings => {
       searchSettings.FilterInterval("displaySearchResult");
   })
   // ...
)
See Also