ImageEn, unit iexUserInteractions

TIEPdfViewer.FindNext

TIEPdfViewer.FindNext


Declaration

function FindNext(ReverseDir: Boolean = False): Boolean;
function FindNext(out CharIndex, CharCount: Integer; ReverseDir: Boolean = False; DoSelect: Boolean = True): Boolean;


Description

Call after Find to locate the next instance of the searched text.
Use the second overload to retrieve information about the location position, and optionally for non-visual searches.
Parameter Description
CharIndex The starting position of the searched text
CharCount The length of the found text
ReverseDir Works backward to return previous found entries
DoSelect If enabled, the instance is marked in the document. If False, the search is non-visual

Result is False if there are no further instances of the searched text.

Note:
You can use ClearSelection to clear the selected text
To access the screen position of the text, use GetTextRects


Demo

Demo  Demos\PDF\PDFViewer\PdfViewer.dpr


Examples

ImageEnView1.PdfViewer.FindNext();

// Find previous instance
ImageEnView1.PdfViewer.FindNext( True );

// Get the location of the "Adobe" (non-visual)
ImageEnView1.PdfViewer.Find( 'Adobe', idx, cnt, False, False, False );
ShowMessage( format( 'Index: %d, Count: %d', [ idx, cnt ]);


See Also

CanFindNext
Find
ClearSelection
FindCountInPage