


Hi,
I want to access desired variables by passing variable name type string to it and it will give me value of the variable.
eg.
variableName (type string)="variable1"; <input parameter>
variableOutResult (type int) <output parameter>
variable1 <int type>=1; (default value)
variable2 <int type>=2; (default value)
using setValue activity. I want to create an expression which will return default value of variable1 or variable2
XPath mapping
(Location) (Expression)
/process_data/@variableOutResult "/process_data/@"+"/process_data/variableName" <red colored string is access to a variable which has value as variable1 or variable2>
underlying vauriable will form "/process_data/@variable1" which should store value to variableOutResult and give result as 1.
Please let me know if you need more clarification.
Regards
Sunil
Views
Replies
Sign in to like this content
Total Likes
Ok, let me explain you in this way.
Precondition: Default value of variable1 is 1, variable2 is 2 and variableOutResult is 0.
Below I want to form an expression that if I pass “variable1” in variableName the variableOutResult should result me 1. If “Variable2” as input parameter pass through variable variableName, the variableOutResult should result me 2.
Please find the attached .lca. I want to pass name of the variable as string to retrieve value in SetValue, NOT in executeScript activity.
I want to get form access to variable variable1 or “/process_data/@variable1”.
here is the .lca file.
Let me know if still I could not explain.
Regards
Sunil
Not able to attach lca but providing you image of the process.
Views
Replies
Sign in to like this content
Total Likes
Not able to attach lca but providing you image of the process.
Views
Replies
Sign in to like this content
Total Likes