FindString

 

Description

 

Search for a string in the pure (tag-free) text and select the string if found. If necessary, the page is scrolled to expose the highlighted string.

 

Arguments

 

Name

Type

I/O

Description

BshowFindDialog

Boolean

In

Set to True to display a Find dialog or False to start the search immediately.

StringToFind

String

In

If an immediate search is specified (bShowFindDialog set to False) this is the string to be found. If a Find dialog is displayed, this string is the default string to search for.

MatchCase

Boolean

In

Determine whether the search is case sensitive.

Reverse

Boolean

In

Determines the search direction.

 

 

Return Value

 

Long Integer: the offset of the found string in the pure-text buffer, or -1 if the string was not found.

 

Remarks

 

When previously found text is selected (highlighted), the next forward Find operation starts after the selected text and a reverse Find starts just before the selected text. If no found text is selected, the forward Find starts with the top-most visible text in the current display and the reverse Find starts with the bottom-most visible text in the current display.