This topic has not yet been rated - Rate this topic

SPListItem.Recycle method

Deletes the item from the content database and returns a globally unique identifier (GUID) for the transaction.

Namespace:  Microsoft.SharePoint
Assembly:  Microsoft.SharePoint (in Microsoft.SharePoint.dll)
[ClientCallableExceptionConstraintAttribute(FixedId = "2", ErrorCode = , Condition = "Item does not exist.The page you selected contains an item that does not exist.  It may have been deleted by another user.", 
	ErrorType = typeof(SPException))]
[ClientCallableMethodAttribute(RemoveThisObjectFromParentCollection = true)]
[ClientCallableExceptionConstraintAttribute(FixedId = "3", Condition = "Method 'Recycle' is not supported on Microsoft.SharePoint.SPListItem for external lists.", 
	ErrorType = typeof(NotSupportedException))]
public Guid Recycle()

Return value

Type: System.Guid
An identifier for the deletion transaction.
ExceptionCondition
NotSupportedException

The parent list has an external data source.

Did you find this helpful?
(1500 characters remaining)

Community Additions

ADD
© 2013 Microsoft. All rights reserved.