findandReplace (NotesRichTextRange - JavaScript™)
Replaces the next occurrence of a string in a rich text range, and moves the current position to the beginning of the first occurrence of the string.
Defined in
NotesRichTextRangeSyntax
findandReplace(target:string,
replacement:string) : int
findandReplace(target:string,
replacement:string, options:long) : int
Parameter | Description |
---|---|
String target |
The search string. |
String replacement |
The replacement string. |
long options |
Any of the following search options. Specify
multiple options by combining them with addition or logical ORs.
|
Return value | Description |
---|---|
int |
The number of replacements made. |
Usage
For purposes of navigation, this method finds an element of type RTELEM_TYPE_TEXTRUN. The current position becomes the first character of the search string within the element (not the first character of the element).The range is reset after a findAndReplace operation.