Ordering Event Handlers
When an event handler is first defined and saved, the system automatically assigns a handler sequence number. When the event handler is first saved, the system checks to see if there are other handlers associated with the named application event. Depending on the results of that check, the system then assigns 1 to the handler (if there are no other handlers associated with the event) or the next available integer (if there are other handlers associated with the event).
In general, then, if an application event uses multiple event handlers, by default, the system uses the handler sequence numbers to determine the order in which the handlers execute.
However, It is possible to indirectly alter this default order. This is done either by:
- Using the Keep With and Chronology fields on the Event Handlers form
- Moving your own adjacent event handlers up or down in the sequence by using the Event Handler Sequence form
To alter the default order in which event handlers execute using the Keep With and Chronology fields on the Event Handlers form: