Using Scripts
Except in the very simplest of processes, the sequence of forms that a user is presented with, and the outcome of the work item, depends on the conditional processing written into the application. That conditionality is governed by scripts. For example, a script could take information from fields completed in one work item and pass it to another, depending on the value of those fields.
In addition, scripts can include operations to create, update or delete data objects. Examples would include creating or updating a customer record, or a new insurance claim.
- Plain text. When you create a process, you may include a plain text description of the desired behavior of any scripts that form part of the process. These plain text entries are not intended to be executable. The plain text script appears as an error in the process and the process cannot be deployed whilst there is a script defined in this way within it.
- JavaScript. Executable scripts are written in JavaScript. Some additional methods compatible with standard JavaScript are provided with ActiveMatrix BPM and can be used in the scripts that you write within TIBCO Business Studio. See Additional JavaScript Global Functions.
- Data Mapper. With Data Mapper, you can graphically map data across datafields and parameters to create complex BOM objects from a combination of process data fields and parameters. This script grammar is available for Script Tasks, Task scripts, Call Sub-Processes, global and local signals, and Catch error events. For more information, see Data Mapping.
Use Ctrl+ SPACE to access content assist in all the areas in which you can enter scripts. You are prompted with a list of words, variables, methods and so on, that are appropriate for where you are in the script.