共用方式為


SPUserCodeExecutionManager.Execute method

執行使用適當的負載平衡使用者程式碼執行伺服器上的使用者程式碼包裝函式物件的要求。

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

Syntax

'宣告
Public Function Execute ( _
    userCodeWrapperType As Type, _
    site As SPSite, _
    executionContext As SPUserCodeExecutionContext _
) As Object
'用途
Dim instance As SPUserCodeExecutionManager
Dim userCodeWrapperType As Type
Dim site As SPSite
Dim executionContext As SPUserCodeExecutionContext
Dim returnValue As Object

returnValue = instance.Execute(userCodeWrapperType, _
    site, executionContext)
public Object Execute(
    Type userCodeWrapperType,
    SPSite site,
    SPUserCodeExecutionContext executionContext
)

參數

  • userCodeWrapperType
    Type: System.Type

    若要啟用遠端使用者程式碼執行伺服器上的包裝函式物件的類型。此值必須指定衍生自SPUserCodeWrapper類別的類型。

傳回值

Type: System.Object
物件,其中包含要求的結果。

Exceptions

Exception Condition
SPUserCodeExecutionPipelineTerminallyFailedException

通訊協定伺服器遇到無法復原和終端機失敗。通訊協定用戶端必須不任何詳細Execute將要求傳送至通訊協定伺服器後此例外狀況,直到Ping方法會傳回true。

SPUserCodeExecutionPipelineFailedException

通訊協定伺服器本身執行使用者程式碼要求試圖時遭遇錯誤。

SPUserCodeSolutionExecutionFailedException

通訊協定的伺服器上所執行的使用者程式碼就會失敗。

SPUserCodeValidationFailedException

失敗時發生驗證包含使用者程式碼組件群組。

請參閱

參照

SPUserCodeExecutionManager class

SPUserCodeExecutionManager members

Microsoft.SharePoint.UserCode namespace