replace $variable,oldString,newString
Where:
$variable | variable containing text to be replaced.. |
oldString | the string to replaced. Enclose oldString in double quotation marks ("") if it contains embedded spaces or commas. |
newString | the replacement string. Enclose newString in double quotation marks ("") if it contains embedded spaces or commas. |
oldString and newString may be variables.
The replace command replaces all occurrences of oldString in $variable with newString.
Example
replace | $variable,dog,cat |
Sample Script
* replace.txt
* replace fox with dog
SetVar $Result,"The quick brown fox"
SetVar $Old,"fox"
SetVar $New,"dog"
replace $Result,$Old,$New
type $Result
exit
TN3270 Plus is continually being improved. To learn more about the latest enhancements, please review our Version History web page.