Event ainsert_before

Description

This event is called after all of the other AINSERT_CONTROL_* events and just before the insertion. The insertion will then be done in the database by using a SetInstance instruction followed by a Write instruction. The insertion can still be refused if an error is set in this event.

Context

The following variables or properties are available in the context:

  • this refers to the current class. All properties can be found using the this.PROPERTY syntax.
  • CURPTH describes the child class path if the method is called on a child class. If the method is called on the main class, CURPTH is empty.
  • AEVENT is equal to AINSERT_BEFORE.