Scripts are only called from user actions. This action can be a user clicking on a button or changing a value in a text box. You can trap such events in every form element. Use scripts or scripting to bind a function to such events (See chapter Forms).
The following shows the possible events.
Event |
Description |
|---|---|
OnClick |
•The user left clicks on the element. |
OnChange |
•The content of a form field changes. |
OnFocus |
•The user positions the cursor on the form field using the mouse or the tab key. |
OnBlur |
•The user moves the cursor out of the form field. |
OnKeyDown |
•The user types a character into a form field. A key press triggers the call. |
OnSelectDate |
•The user selects a date from a calendar. |
Not all field types have all events available. They vary according to the different requirements and the point in time at which a script is called. Use OnChange to verify input of changed field values, and use OnClick to register a button click.