Hi everyone,
I’m Darshan Hiranandani, trying to use the "Run JavaScript" action with manual input, but I need help with referencing a variable that I’ve already defined in RPA.
For example, I have a variable $variableInRPA$
(with a value like 50) and I want to use this variable inside a JavaScript block to add 10 to it and return the result.
Here’s what I have so far:
(function(){ var variableInManualInput = $variableInRPA$; var result = variableInManualInput + 10; return result;}());
However, I'm not sure if $variableInRPA$
will work directly in the JavaScript block.
Has anyone done something similar, and could you suggest how I might reference the RPA variable correctly in the JavaScript?
Looking forward to hearing your thoughts!
Thanks!
Regards
Darshan Hiranandani