共用方式為


SPLog.GetInstance method (String)

傳回屬於指定類別的記錄檔物件的執行個體。

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

Syntax

'宣告
Public Shared Function GetInstance ( _
    category As String _
) As SPLog
'用途
Dim category As String
Dim returnValue As SPLog

returnValue = SPLog.GetInstance(category)
public static SPLog GetInstance(
    string category
)

參數

  • category
    Type: System.String

    包含記錄檔所屬的類別名稱的字串。

傳回值

Type: Microsoft.SharePoint.Upgrade.SPLog
表示記錄檔的SPLog物件。

備註

如果category參數包含a null reference (Nothing in Visual Basic), GetInstance方法會傳回System.ArgumentNullException例外狀況。

請參閱

參照

SPLog class

SPLog members

GetInstance overload

Microsoft.SharePoint.Upgrade namespace