SPUtility.ObjectToGuid method
將物件轉換成Guid結構。
Namespace: Microsoft.SharePoint.Utilities
Assembly: Microsoft.SharePoint (in Microsoft.SharePoint.dll)
Syntax
'宣告
Public Shared Function ObjectToGuid ( _
o As Object _
) As Guid
'用途
Dim o As Object
Dim returnValue As Guid
returnValue = SPUtility.ObjectToGuid(o)
public static Guid ObjectToGuid(
Object o
)
參數
o
Type: System.Object要轉換的物件。
傳回值
Type: System.Guid
如果GUID、 string或byte[]物件的類型,這個方法會傳回有效Guid。否則,它會傳回GUID.Empty。