Freigeben über


SPLongOperation.BeginOperation-Delegat

Definiert die Signatur einer Stellvertretung, die einen long-Vorgang beginnt.

Namespace:  Microsoft.SharePoint
Assembly:  Microsoft.SharePoint (in Microsoft.SharePoint.dll)

Syntax

'Declaration
Public Delegate Sub BeginOperation ( _
    longOperation As SPLongOperation _
)
'Usage
Dim instance As New BeginOperation(AddressOf HandlerMethod)
public delegate void BeginOperation(
    SPLongOperation longOperation
)

Parameter

Hinweise

Sie können diese Delegatenmethode mit der statischen SPLongOperation.Begin(SPLongOperation.BeginOperation) -Methode, verwenden, wie im folgenden Beispiel dargestellt:

SPLongOperation.Begin(
    delegate(SPLongOperation longOperation)
    {
        // Do something that takes a long time to complete.
        
        
        // Inform the server that the work is done
        // and that the page used to indicate progress
        // is no longer needed.
        longOperation.End("default.aspx");
    }
);
' Do something that takes a long time to complete.
' Inform the server that the work is done
' and that the page used to indicate progress
' is no longer needed.
SPLongOperation.Begin(Function(longOperation) AnonymousMethod1(longOperation))

Private Function AnonymousMethod1(ByVal longOperation As SPLongOperation) As Object
longOperation.End("default.aspx")
Return Nothing
End Function

Siehe auch

Referenz

Microsoft.SharePoint-Namespace

Begin(SPLongOperation.BeginOperation)