Check ending Version 5 (Java)
Action group: Text
Description
Determines if the ending of the text matches the specified pattern
Action icon
Settings of parameters
Property | Description | Type | Filling example | Mandatory field |
Parameters | ||||
Source text | Text to make action on | Robin.String | Yes | |
Estimated ending | The text to which the end of the source text will be compared | Robin.String | Yes | |
Results | ||||
Result | Boolean variable to which the test result will be written | Robin.Boolean | true |
Special conditions of use
None.
Example of use
Task
There is a text variable "Input text" with value = LKM Click, text variable "Text for comparison" with value = "LMB". It is necessary to check whether the end of the text coincides with the specified sample. If the condition matches, output the message - "the end of the text matches the specified pattern", if it does not match "the end of the text does NOT match the specified pattern".
Solution
Use the "Check ending", "If", and "Show message" actions.
Implementation
- Create a boolean variable to which the result of the "Check start" action will be written.
- Move the "Check ending" action to the workspace and set its parameters.
- Move the "If" action to the workspace and set its parameter.
- Add a "Show message" action to the "Truth" branch and set its parameter.
- In the "False" branch, add a "Show message" action and set its parameter.
- Launch the robot using the "Start" button in the top panel.
Result
The result is displayed in the dialog box.
Обзор
Инструменты контента