4D v16.3On Host Database Event database method |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
4D v16.3
On Host Database Event database method
On Host Database Event database method
The On Host Database Event database method allows 4D components to execute code when the host database is opened and closed. Note: For security reasons, in order to be able to call this database method, you must explicitly allow its execution in the host database. For more information about this point, refer to the Design Reference manual. The On Host Database Event database method is executed automatically only in databases used as components of host databases (when it is authorized in the Settings of the host database). It is called when events related to the opening and closing of the host database occur. To process an event, you must test the value of the $1 parameter inside the method, and compare it with one of the following constants, available in the "Database Events" theme:
This allows 4D components to load and save preferences or user states related to the operation of the host database. Example of typical structure of an On Host Database Event database method: // On Host Database Event database method
|
PROPERTIES
Product: 4D
HISTORY
Created: 4D v14 ARTICLE USAGE
4D Language Reference ( 4D v16) |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||