Start search in the code behind. .net viewer

Hi Denis,



Can you post the sample code to use the searchforward method after the viewer loads?



Thanks.

Antonio

Hello Antonio,

Here is full source code of the page.

<%@ Page Language=“C#” AutoEventWireup=“true” CodeBehind=“page5.aspx.cs” Inherits=“ViewingFromStream.page5” %>






Page 5
<%=Groupdocs.Web.UI.Viewer.CreateScriptLoadBlock().LoadJquery(true).LoadJqueryUi(true).UseHttpHandlers()%>






IsCaseSensitive







<%= Groupdocs.Web.UI.Viewer.ClientCode().TargetElementSelector("#test")
.FilePath(“candy.pdf”)
.UseInnerThumbnails(true)
.UseHtmlBasedEngine(true)
.SupportPageRotation(true)
%>















Please take into account the last JS block - it does what you need.

And here is a screenshot of the page in the browser right after the moment when document was loaded.