Develop > Programming Guide > Where can I use JavaScript in Service Manager? > Order of execution of JavaScript versus RAD language

Order of execution of JavaScript versus RAD language

This section lists all tailoring tools in which JavaScript can be directly entered and describes at what point in the process the JavaScript code will be executed.

  • Format Control: The JavaScript is executed after calculations and before validations. JavaScript code in Format Control is executed via the format.cjavascript RAD.
  • Links: JavaScript in links is executed after the (initial) expressions, but before the fill or find is executed. This is done in us.link on evaluate.expressions.
  • The post JavaScript is executed after the fill or find was performed, immediately after the post expressions. This happens in us.fill or us.find, respectively, on the eval.post.expressions panel.
  • Triggers: The JavaScript in the triggers file is executed after the RAD application. This is controlled by the server binaries and not by RAD code.
  • Cascade updates: The JavaScript in cascade updates is executed from the RAD application process.update.config.record. The evaluate expressions panel is executed before the evaluate.javascript panel, so that expressions take precedence over JavaScript.
  • Scripts: In script.execute on panel exec.statements, RAD expressions are processed before JavaScript expressions.
  • Wizards: Wizards use JavaScript in three different areas: During File Selection, Actions, and Cancel Expressions.

    • File Selection: The Select $L.file by information is processed first, followed by the Initial Expressions and then the JavaScript.
    • Actions: In the Actions tab, the Expressions are run first, then the JavaScript, followed by the information on the Format Control / Process Name tab.
    • Cancel Expressions: First the Expressions Executed on Cancel are processed, followed by Javascript Executed on Cancel.
  • Interoperability (ioaction file) : The ioaction file executes only JavaScript and not RAD expressions. The JavaScript code is executed in the ioevents.process.action application on the process.action panel .
  • Display screens: In the display application on the panel prep.screen, the JavaScript expressions are executed after the RAD expressions.
  • Display options: Display options have pre- and post-JavaScript and RAD expressions that are executed in the following order:

    1. Pre-RAD expression
    2. Pre-JavaScript
    3. RAD application
    4. Post-RAD expression
    5. Post-JavaScript
    6. Display Action
  • Processes: Process records have initial and final JavaScript and RAD expressions executed in the following order:

    1. Initial RAD expression
    2. Initial JavaScript
    3. Pre-RAD expressions
    4. RAD application(s)
    5. Post-RAD expressions
    6. Final RAD expression
    7. Final JavaScript
    8. Next Process (if applicable)
  • Schedule: JavaScript in the schedule record is executed after the RAD application is called and before the check for deleting or rescheduling the schedule record.