OnLoad Events

Prev Next

In Construct Preview, OnLoad events execute validation rules or business logic when a page container (a grid or form) loads, allowing for dynamic data population. These events run asynchronously in the background, meaning they don't slow down or block your page and container from being displayed.

Use OnLoad events sparingly. Executing a SQL stored procedure increases page load time, which should remain under one second for optimal user experience.

Note

OnLoad events execute only once when a page's container initially loads. They do not execute during data entry, container re-renders, or tab switches.

When an OnLoad event completes, any validation results are displayed in the Event Validation Results dialog box:

  • Success Messages: Confirms that the event executed successfully

  • Warning Messages: Alerts you to potential issues that don't prevent the event.

  • Error Messages: Indicates critical issues that require attention. Address the reported validation failures.