<< Click to Display Table of Contents >> Navigation: Actions > Regular Expressions > RegExp Match |
This action is in fact a simplified version of RegExp Loop. By means of this action it is possible to determine if a string (or a text) corresponds to the specified regular expression and also to extract the first or the last entry.
General
External Text
Input the name of the text file in which the search will be implemented. Variables can be used.
Specified Text
In this field specify the text in explicit form on which you want to search. You can use variables.
Pattern (Regular Expression)
Input a regular expression (a phrase mask) for the search in a text. You can find description of regular expression syntax and manuals on the site http://www.regular-expressions.info/
Save TRUE or FALSE to variable
Input the variable name in which you want to save the check result.
Additional options
Case Insensitive
Tries to match the regex without paying attention to case. If set, 'Bye' will match 'Bye', 'bye', 'BYE' and even 'byE', 'bYe', etc. Otherwise, only 'Bye' will be matched. Equivalent to (?i) modifier. The modifier (?-i) switches off the mode case insensitive.
MultiLine
The ^ (beginning of string) and $ (ending of string) regex operators will also match right after and right before a newline in the Subject string. This effectively treats one string with multiple lines as multiple strings. Equivalent to Perl's (?m) modifier. The modifier (?-m) switches off the mode multiline.
Single Line
Normally, dot (.) matches anything but a newline (\n). With Single Line mode, dot (.) will match anything, including newlines. This allows a multiline string to be regarded as a single entity. Equivalent to Perl's (?s) modifier. The modifier (?-s) switches off the mode single line.
Note that MultiLine and Single Line can be used together.
Extended Style
Allow regex to contain extra whitespace, newlines and Perl-style comments, all of which will be filtered out. This is sometimes called "free-spacing mode".
Anchored
Allows the regex to match only at the start of the subject or right after the previous match.
Ungreedy
Repeat operators (+, *, ?) are not greedy by default (i.e. they try to match the minimum number of characters instead of the maximum).
No Autocapture
Is a non-capturing group, only named groups will be captured.
Save Found Subexpressions
If you need to save a found expression in a variable, switch on this checkbox and then fill in the saving parameters. You can save either the first entry or the last one. The found expression with its subexpressions will be saved as a comma-separated string. A zero element is the whole expression. The next elements are subexpressions in order.
Related Topics