Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
Export (0) Print
Expand All

DataServiceContext.DeleteObject Method

Changes the state of the specified object to Deleted in the DataServiceContext.

Namespace:  System.Data.Services.Client
Assembly:  System.Data.Services.Client (in System.Data.Services.Client.dll)

public void DeleteObject(
	Object entity
)

Parameters

entity
Type: System.Object
The tracked entity to be changed to the Deleted state.

ExceptionCondition
ArgumentNullException

When entity is null.

InvalidOperationException

When entity is not being tracked by the context.

All links to the specified entity are also marked Deleted.

For examples that use the DeleteObject method, see Modifying and Deleting Entity Data (WCF Data Services/Silverlight).

Silverlight

Supported in: 5, 4, 3

For a list of the operating systems and browsers that are supported by Silverlight, see Supported Operating Systems and Browsers.

Community Additions

ADD
Show:
© 2015 Microsoft