Free Support Forum -

Opening Viewer with string set in search control and highlited in the body


Hi ,

Is this possible to be done?
I would like to open the viewer with all ready predefined string set in the search control and that text or string to be found and highlighted in the text of the body of the document displayed.
This would like the normal procedure when you open the document for viewing and writting the string manually in the search bar and clicking or pressing enter to find it, but this way would be automatically set when invoked.
Can this be acheaved by some internal method? or maybe some other way?

Thanks in advance,


Hello Goran,

Thank you for the request. Yes, this is possible with the GroupDocs.Viewer JavaScript API. You will need to call "searchForward " method on document ready event. For more info and how to use the "searchForward " please check step 15 in this documentation .

Best regards.