Quote from
Gaev on December 30, 2023, 11:12 pm
@adrianbrookbank
Say ...
1) the TextEntry object is called TextEntry8 ... and its associated variable is [TextEntry8]
2) you have pre-defined variables like so ...
SetVar "[firstName]" "Jane"
SetVar "[lastName]" "Doe"
Then, have a button whose click event code is ...
SetVar "[resolvedText]" "[TextEntry8]"
StrReplace "[resolvedText]" "[#91]firstName[#93]" "[firstName]" "[resolvedText]" ""
StrReplace "[resolvedText]" "[#91]lastName[#93]" "[lastName]" "[resolvedText]" ""
Say, the user types ...
My first name is [firstName] and my last name is [lastName]
... then, when the user clicks on the button, [resolvedText] will have the value ...
My first name is Jane and my last name is Doe
@adrianbrookbank
Say ...
1) the TextEntry object is called TextEntry8 ... and its associated variable is [TextEntry8]
2) you have pre-defined variables like so ...
SetVar "[firstName]" "Jane"
SetVar "[lastName]" "Doe"
Then, have a button whose click event code is ...
SetVar "[resolvedText]" "[TextEntry8]"
StrReplace "[resolvedText]" "[#91]firstName[#93]" "[firstName]" "[resolvedText]" ""
StrReplace "[resolvedText]" "[#91]lastName[#93]" "[lastName]" "[resolvedText]" ""
Say, the user types ...
My first name is [firstName] and my last name is [lastName]
... then, when the user clicks on the button, [resolvedText] will have the value ...
My first name is Jane and my last name is Doe