Right

This is pre-built Action located under the @Generic Element Name. It instructs the Avo Assure Client to fetch the characters started from desired position, from the right side of String and store the result in an output variable.

Syntax

Input: <string>;<position to fetch the string from>

  • string: It is the actual string from which a number of characters are fetched from the right side from a specified position.

  • position to fetch the string from: It is the position from right hand side of a string starting from which position the characters from a string are fetched.

Output: <Dynamic Variable>;<Dynamic Variable>(Optional)

Usecase/Example

Scenario: Order Confirmation Number Retrieval in an E-commerce Application

In an e-commerce application, after you complete a purchase, the system generates an order confirmation number that may include various characters (letters and numbers). For testing purposes, you need to extract the last few characters of this order number to verify its format or to use it in subsequent steps of the test.

Input

After placing an order, the application generates an order confirmation number, such as:

  • ORD-2024-XYZ12345

  • ORD-2024-ABC67890

  • ORD-2024-DEF54321

Expected Result

Five characters from actual string needs to be extracted from right side.

Output

The output is stored in the {result} output variable as 12345, which can be utilized for display or other purposes.

Last updated

Was this helpful?