Skip to main content
.NET 8.0+

DevExpress v24.2 Update — Your Feedback Matters

Our What's New in v24.2 webpage includes product-specific surveys. Your response to our survey questions will help us measure product satisfaction for features released in this major update and help us refine our plans for our next major release.

Take the survey Not interested

BaseObjectSpace.Delete(IList) Method

Marks the specified persistent objects and their aggregated objects as deleted from the database.

Namespace: DevExpress.ExpressApp

Assembly: DevExpress.ExpressApp.v24.2.dll

NuGet Package: DevExpress.ExpressApp

#Declaration

public virtual void Delete(
    IList objects
)

#Parameters

Name Type Description
objects IList

A collection of persistent objects to be deleted from the database.

#Remarks

Use this method to delete the objects passed as the objects parameter from the database. This method calls a protected virtual method, DeleteCore, which must be overridden in the BaseObjectSpace class descendants. Note that the objects cannot be deleted immediately. The BaseObjectSpace.SetModified method is called so that the deleted objects are marked as modified, and therefore, are deleted from the database during the next changes commit (see BaseObjectSpace.CommitChanges).

You can implement a custom delete operation instead of the one performed by the DeleteCore method. To do this, subscribe to the BaseObjectSpace.CustomDeleteObjects event and set the event handler’s Handled parameter to true.

#Implements

See Also