共用方式為


SPFolder.Recycle Method

Sends the folder to the recycle bin.

Namespace:  Microsoft.SharePoint
Assembly:  Microsoft.SharePoint (in Microsoft.SharePoint.dll)
Available in Sandboxed Solutions: Yes
Available in SharePoint Online

Syntax

'Declaration
<ClientCallableMethodAttribute(RemoveThisObjectFromParentCollection := True)> _
<ClientCallableExceptionConstraintAttribute(FixedId := "1", Condition := "Lack of permissions to perform the operation.",  _
    ErrorType := GetType(UnauthorizedAccessException))> _
Public Function Recycle As Guid
'Usage
Dim instance As SPFolder
Dim returnValue As Guid

returnValue = instance.Recycle()
[ClientCallableMethodAttribute(RemoveThisObjectFromParentCollection = true)]
[ClientCallableExceptionConstraintAttribute(FixedId = "1", Condition = "Lack of permissions to perform the operation.", 
    ErrorType = typeof(UnauthorizedAccessException))]
public Guid Recycle()

Return Value

Type: System.Guid
A System.Guid that represents the transaction ID of the delete transaction.

See Also

Reference

SPFolder Class

SPFolder Members

Microsoft.SharePoint Namespace