Task Output Variables
Allows you to create variables after running the task : usually you will treat the result of the task. These variables can also be used later in the process.
Output variables
This table allows you to define parameters evaluated at runtime after the completion of the task. The first column refers to the variables' name, the second column defines its value: each of the two fields may result from the dynamic evaluation of a formula. If you want your variable to be evaluated in a given order, drag and drop it to move it upward or downward. If you want a variable to be secured (ie. not visible in Process reports Parameters tab), check box "Secured".
[Add]
Click this button to add output variables.
Name
Name of the variable (i.e. myresult_list
).
Value
The value can be fixed (i.e. [1,2,3]
), or dynamic (i.e. ${P_result.feed.entry.id}
).
Secured
A secured variable is a variable that won't be visible in Launched process Parameters tab : it is not sent by RunMyProcess server.
A simple yet powerful scripting and templating language is used to define mappings, based on FreeMarker. For example, mappings may include mathematical operators, string manipulation, logical operators and choices, manipulation of a list of values, etc.
You can test your Freemarker script directly in RunMyprocess without launching the process. For that, click on and read Input and Output Variables Tester
You can now write your script in Javascript script instead of Freemarker thanks to a new Freemarker tag :
<@script env="javascript">
function somme(a ,b) {
var sum=new Number(a) + new Number(b);
return sum;
}
setVariable("sum", somme(a, b));
</@script>
You must use setVariable ("name of variable","value")
function to extract value of javascript to a process variable. You can use directly variables from your process by calling them with their name : var tmp=myprocess_var
(you don't need to write var tmp="${myprocess_var}"
as in RunMyProcess webform).
Freemarker tester does not work for Javascript scripting : you must launch process to test it
Trick : To create several variable in one line, leave variable name empty and create a JSON structure in value. For example
{"var1":"value1","var2":"value2"}
will create var1 and var2 in process.
Internal variables
Some variables are set automatically at process runtime; their name starts with P_ and any name starting with that prefix must be considered as reserved for future use.
For more information on the existing parameters or about Freemarker language, please see How to use Freemarker.
Please give details of the problem