BeginTextSearch

Text and extraction

Description

Builds a reusable search result set in one extraction pass

Returns the number of matching text blocks and resets the traversal position to the first hit

Syntax

Delphi

Function BeginTextSearch(Const Query: WideString; Options: TPDFlibSearchOptions; Const PageRange: WideString): Integer;

Parameters

QuerySearch text; an empty value clears any active session and returns 0
OptionsAny combination of soCaseSensitive, soWholeWord, soDiacriticInsensitive, soWildcards, soAcrossLines, soPreserveStyle, soCanonicalEquivalent and soGraphemeClusters
PageRangePage-range expression, or an empty string for every page

Return values

NNumber of matching text blocks retained for the session
0No document is selected or Query is empty