Text - Reverse
Declaration
<AMTEXT ACTIVITY="reverse" TEXT="text" RESULTVARIABLE="text" />
Overview
Reverses the specified text.
Practical usage
Commonly used to reverse a block of text contained in a text file.
Parameters
Resource
| Property | Type | Required | Default | Markup | Description |
|---|---|---|---|---|---|
| Text | Text | Yes | (Empty) | TEXT="text to reverse" | The target text to reverse. As with every text parameter, if the data you want to enter is contained in a variable, enter the variable name surrounded by percent signs (%) to resolve it to its contents at runtime (for example, %VarName%). |
| Populate variable with result | Text | Yes | (Empty) | RESULTVARIABLE="reversedText" | The name of an existing variable to receive the newly reversed text. |
Example
NOTE:
- Copy and paste the sample AML code below directly into the Task Builder Steps Panel.
- To successfully run the sample code, update parameters containing user credentials, files, file paths, or other information specific to the task to match your environment.
Description
The following task displays an input box requesting the user to input text they want to see reversed and displays the results in a message:
Copy
<AMVARIABLE NAME="theText" />
<AMSHOWDIALOG ACTIVITY="input" MESSAGE="Text to reverse" DEFAULTVALUE="Enter text to reverse here..." RESULTVARIABLE="theText" WINDOWTITLE="Text before Reverse activity is performed." />
<AMTEXT ACTIVITY="reverse" TEXT="%theText%" RESULTVARIABLE="theText" />
<AMSHOWDIALOG WINDOWTITLE="Text after Reverse Text activity is performed.">%theText%</AMSHOWDIALOG>