Breaking Change T1166123
Visible to All Users

Web Document Viewer - The default search mechanism has changed

What Changed

In v23.1, we implemented a new search mechanism for Web Document Viewer. The new mechanism shows the number of search results and allows you to browse through them while the search is in progress. You can also stop the search process at any time.

Previous versions:

sync-search

v23.1:

async-search

Reasons for Change

This change enhances the search experience in Web Document Viewer. The new search mechanism allows you to asynchronously search documents and browse the search results with no need to wait for the entire document to be scanned. The mechanism also allows you to stop the search process at any time.

Impact on Existing Apps

This change affects user experience in applications with Web Document Viewer.

How to Update Existing Apps

The application is updated automatically when you upgrade to v23.1.

How to Revert to Previous Behavior

Set UseAsyncSearch to false to revert to the previous behavior.

ASP.NET Core:

If you bind your control to a WebDocumentViewerModel object, set the UseAsyncSearch property to false:

C#
\\... public async Task<IActionResult> Viewer( [FromServices] IWebDocumentViewerClientSideModelGenerator clientSideModelGenerator, [FromQuery] string reportName) { var reportToOpen = string.IsNullOrEmpty(reportName) ? "TestReport" : reportName; var model = new Models.ViewerModel { ViewerModelToBind = await clientSideModelGenerator.GetModelAsync(reportToOpen, WebDocumentViewerController.DefaultUri) }; model.ViewerModelToBind.SearchSettings.UseAsyncSearch = false; return View(model); }

If you bind to a report object or by a report name, set UseAsyncSearch to false:

Razor
@{ var viewerRender = Html.DevExpress().WebDocumentViewer("DocumentViewer") .SearchSettings(s => s.UseAsyncSearch = false) .Height("100%") .Bind(new TestReport()); @viewerRender.RenderHtml() }

ASP.NET MVC

Razor
@Html.DevExpress().WebDocumentViewer(settings => { settings.Name = "WebDocumentViewer1"; settings.SettingsSearch.UseAsyncSearch = false; }).Bind("TestReport").GetHtml()

ASP.NET Web Forms

ASPx
<dx:ASPxWebDocumentViewer ID="ASPxWebDocumentViewer1" runat="server"> <SettingsSearch UseAsyncSearch="false" /> </dx:ASPxWebDocumentViewer>

Disclaimer: The information provided on DevExpress.com and affiliated web properties (including the DevExpress Support Center) is provided "as is" without warranty of any kind. Developer Express Inc disclaims all warranties, either express or implied, including the warranties of merchantability and fitness for a particular purpose. Please refer to the DevExpress.com Website Terms of Use for more information in this regard.

Confidential Information: Developer Express Inc does not wish to receive, will not act to procure, nor will it solicit, confidential or proprietary materials and information from you through the DevExpress Support Center or its web properties. Any and all materials or information divulged during chats, email communications, online discussions, Support Center tickets, or made available to Developer Express Inc in any manner will be deemed NOT to be confidential by Developer Express Inc. Please refer to the DevExpress.com Website Terms of Use for more information in this regard.