Replace Text

From Appmethod Topics
Jump to: navigation, search

Go Up to Search Menu

Search > Replace    Ctrl+R

Searches for the specified text and then replaces with other text.

Item Description

Text to find

Enter a search string or use the down arrow to select a previously entered search string.

Replace with

Enter the replacement string. To select from a list of previously entered search strings, click the down arrow next to the input box. To replace the text with nothing, leave this input box blank.

You can use the following escape sequences in the replacement string:

Escape sequence Description
\\

Prints a single backslash.

A single backslash (\) is interpreted as an escape character, even if the character that follows the backslash does not need to be escaped. For example, if you write "\b" in the replacement string, "b" is printed. To print a single backslash, you must escape the backslash with another backslash (\\). For example, if you write "\\b" in the replacement string, "\b" is printed.

\n Prints a new line.
\r Prints a new line.
\t Prints a tab.

For example, if your replacement string is "line1\n\tline2 \\", the resulting string is:

line1
   line2 \

Case sensitive

Differentiates uppercase from lowercase when performing a search.

Whole words only

Searches for words only. If unchecked, the search string might be found within longer words.

Regular expressions

Recognizes Regular Expressions in the search string.

Prompt on replace

Displays a confirmation prompt before replacing each occurrence of the search string. If unchecked, the Code Editor automatically replaces the search string.

Forward

Searches from the current position to the end of the file. Forward is the default.

Backward

Searches from the current position to the beginning of the file.

Global

Searches the entire file in the direction specified by the Direction setting. Global is the default scope.

Selected text

Searches only the selected text in the direction specified by the Direction setting. You can use the mouse or block commands to select a block of text.

From Cursor

Starts the search at the current cursor position, and then proceeds either forward to the end of the scope, or backward to the beginning of the scope depending on the Direction setting.

Entire scope

Searches the entire block of selected text or the entire file (no matter where the cursor is in the file), depending on the Scope options.

Replace All

Replaces every occurrence of the search string. If checked, the Confirm dialog box appears on each occurrence of the search string.