Open topic with navigation


Scriptcase uses the concept of events to enable the developer to customize application code. Events allow the developer to define custom actions at a specific execution time (e.g. After a record is inserted, when it is loaded, upon submitting a form, ...) and for a specific type of application.

OnInit - This event is executed just one time, before the main select of the application execution. In this scope, normally, are executed the macros that update the select, as these: sc_select_field, sc_select_order,sc_select_where(add) and etc.

onRecord - This event is executed before displaying each grid record.

onHeader - This event is executed immediately before displaying the grid header. Use this event to print some calculated value in the header for example.

onFooter - Used to display some calculated value. Write in this event the necessary calculation to display the result in the footer.

Any event can use pre-defined functions (macros) that are available in Scriptcase. These functions are called "Scriptcase Macros".