Trim
This is a pre-built Action located under the @Generic Element. The functionality of this Action in Avo Assure is to remove extra spaces at the beginning and end of the input text. The updated text is then stored in a dynamic variable.
Syntax
Input Value: <input string>
<input string>
(Required)
Provide the string from which the spaces need to be removed.
Output Value: <Dynamic Variable>;<Dynamic Variable>(Optional)
<Dynamic Variable>
(Required)
This dynamic variable stores the trimmed string.
<Dynamic Variable>
(Optional)
This dynamic variable stores the operation status as True or False.
Example: Trimming Extra Spaces from a String
In this example, we explain how to remove unwanted spaces from the beginning and end of a string.
Action: Trim
Input Value: Alice
This specifies the string that contains leading and trailing spaces to be removed.
Output Value: {Trimmed String}
The trimmed result (e.g., Alice) is stored in this {Trimmed String} dynamic variable for further use.
If the second output variable is defined, it stores the action status with the following possible values:
True: If the trimming is successful.
False: If the trimming fails due to invalid input or configuration.
Logical Explanation: The Trim action fetches the value from the Input Value column ( Alice ) and removes the extra spaces from both ends. The resulting string (Alice) is then stored in the {Trimmed String} variable.

Knowledge Bites: Below are some examples of different string scenarios
Text Strings
" Automation "
Automation
Numeric Strings
" 123456 "
123456
Alphanumeric strings
" ID2025 "
ID2025
Last updated
Was this helpful?