OpenWGA 7.7 - TMLScript reference
WGA » WGA.JobsMethod :
runScriptModule(module, [, customOptions])
On object | WGA.Jobs |
Usage | Runs the code of a TMLScript module as a job |
Description |
Running a TMLScript module as a job is equivalent to creating a job, adding a single task of type "TMLScript" to it, and specifying a TMLScript module to run. However the job created and run by this method will be transient, which means that it will be gone again after it has finished running. The job is given a generated job name which is returned by this method and can be used to monitor it. The customOptions that can be passed optionally to the job will be available to the TMLScript module code via jobContext.getOption(). |
Parameters |
module (String): Design reference of the script module customOptions (Lookup table, optional): Optional additional options for the script, retrievable via jobContext.getOption() |
Return value | Name of the transient job (String) |
Allowed in script types |
|
Examples |
Running TMLScript module "jobs:validatecontents" as Job: WGA.Jobs.runScriptModule("jobs:validatecontents"); |