Occurs before an application deletes the current entity from the database.
property OnDelete: TOnModifyEvent;
Write a OnDelete event handler to take specific action when the dataset deletes the current entity from the database. OnDelete is triggered when an application calls the Delete method. Delete checks whether the entity corresponding to the currect record exists, calls the BeforeDelete event, then retrieves the current entity and calls the OnDelete event.
In the OnDelete event handler, the DataSetAction parameter has the daDelete value.
The ApplyAction parameter defines which actions have to be performed to the current entity after the event is called: