Types of triggers

There are five trigger types supported in Dexterity. The following sections explain each briefly.

Form triggers

When a form trigger is registered for a form, an “Additional” menu is added for windows in the form in Microsoft Dynamics GP. In the registration, you specify a menu item that will appear in the “Additional”. When the user selects this menu item, the form trigger is activated, allowing your application to respond. Typically, form triggers are used to provide navigation to your form without customizing the Microsoft Dynamics GP form with a navigational control (such as a push button).

Focus triggers

Focus triggers are activated by focus events, such as a window opening or closing, or the focus moving from field to field. Focus events occur in any location where Dexterity allows you to attach a script, such as window pre and post scripts, or field pre, change and post scripts.

A focus trigger can be activated by any focus event on the form (such as when the user clicks the Save button, or restarts the form). This gives you the same functionality as attaching a script directly to a form, without modifying the form directly.

Database triggers

Database triggers are activated by successful table operations, such as a record begin read, saved, or deleted. The procedure that runs in response to a database trigger has access to the same table buffer contents as the script that performed the database operation.

Database triggers are useful for maintaining referential integrity between records in your application and related records in the accounting system. When Microsoft Dynamics GP reads, saves or deletes a record, you can use a database trigger to perform similar operations for a related table in your application.

Procedure triggers

A procedure trigger is activated when a specific procedure is run. The trigger processing procedure runs either before or after the procedure being triggered from and has access to the same parameters as the original procedure.

Function triggers

A function trigger is activated when a specific function is run. You can run a function or procedure in response to the function being triggered from. The function or procedure that runs in response to the function call can run before or after the original function.


Documentation Feedback