다음을 통해 공유


SPThreadPool.QueueUserWorkItemWithUserToken Method

Queues a method for execution by using the specified user token.

Namespace:  Microsoft.SharePoint.Utilities
Assembly:  Microsoft.SharePoint (in Microsoft.SharePoint.dll)
Available in Sandboxed Solutions: No

Syntax

'Declaration
Public Shared Function QueueUserWorkItemWithUserToken ( _
    callback As WaitCallback, _
    state As Object, _
    token As SPUserToken _
) As Boolean
'Usage
Dim callback As WaitCallback
Dim state As Object
Dim token As SPUserToken
Dim returnValue As Boolean

returnValue = SPThreadPool.QueueUserWorkItemWithUserToken(callback, _
    state, token)
public static bool QueueUserWorkItemWithUserToken(
    WaitCallback callback,
    Object state,
    SPUserToken token
)

Parameters

  • state
    Type: System.Object

    An object that contains data to be used by the method.

Return Value

Type: System.Boolean
true if the method is successfully queued; otherwise, false.

See Also

Reference

SPThreadPool Class

SPThreadPool Members

Microsoft.SharePoint.Utilities Namespace