Client script types

Client scripts are shipped to the client (the browser) and run there instead of on the server.

Users who know JavaScript can define scripts to run in the client browser. Several types of scripts are supported:
  • onLoad(): Runs when a form is loaded.
  • onChange(): Runs when a particular widget changes value.
  • onSubmit(): Runs when a form is submitted.
  • onCellEdit(): Runs when a cell on a list changes value.
Note: Best practice for performance reasons is to limit the amount of code sent to the client. You should always be aware of the impact on the client when adding client scripts.
Warning:
  • Warning:
  • With the exception of onCellEdit client scripts, UI policies and client scripts apply to forms only. If you create UI policies or client scripts for fields on a form, you must use another method to ensure that data in those fields is similarly controlled in a list. You can:
  • Disable list editing for the table.
  • Create appropriate business rules or access controls for list editing.
  • Create data policies.
  • Create a separate onCellEdit client script.