System.Web.UI.WebControls.DetailsView.DeleteItem Method

Deletes the current record from the data source.

Syntax

public virtual void DeleteItem ()

Remarks

The deletion does not occur if the System.Web.UI.WebControls.DetailsView control is in Insert mode. The DetailsView.ItemDeleting event is raised immediately before the item is deleted. Set the System.ComponentModel.CancelEventArgs.Cancel property to true to cancel the deletion.

Requirements

Namespace: System.Web.UI.WebControls
Assembly: System.Web (in System.Web.dll)
Assembly Versions: 2.0.0.0
Since: .NET 2.0