Workflow setGlobal
Revision as of 11:24, 30 December 2024 by Administrator (talk | contribs) (Created page with "== Workflow_setGlobal== Set values for scripts invoked from workflow class ==Syntax== Workflow_setGlobal(string parameterName, AnyType value) == Return type == Empty == Exampl...")
Workflow_setGlobal
Set values for scripts invoked from workflow class
Syntax
Workflow_setGlobal(string parameterName, AnyType value)
Return type
Empty
Examples
//Use on dynamic script
string script = "
number a = 1;
return a + Workflow_getGlobal(\"x\");
";
WorkflowScript wf = new WorkflowScript (script, false);
Workflow_setGlobal("x", 10);
wf.Call();//11
//Use on existing wokflow
WorkflowScript wf = new WorkflowScript (wf);
Workflow_setGlobal("x", 10);
print(wf.Call());//11
// script get global value on the above wf:
number a = 1;
return a + Workflow_getGlobal("x");