Skip to content

TDataSet.OnDeleteError

Event triggered when a delete operation fails.

Declaration

Source position: db.pas line 1991

public property OnDeleteError: TDataSetErrorEvent;

Description

OnDeleteError is triggered when the TDataset.Delete method fails to delete the record in the underlying database. The event handler can be used to indicate what the response to the failed delete should be. To this end, it gets the exception object passed to it (parameter E), and it can examine this object to return an appropriate action in the DataAction parameter. The following responses are supported:

daFail
The operation should fail (an exception will be raised).
daAbort
The operation should be aborted (edits are undone, and an EAbort exception is raised).
daRetry
Retry the operation.

For more information, see also the description of the TDatasetErrorEvent event handler type.

See also

Name Description
TDatasetErrorEvent Error handling callback.
TDataset.Delete Delete the current record.
TDataset.OnEditError Event triggered when an edit operation fails.
TDataset.OnPostError Event triggered when a post operation fails.