共用方式為


SPListItem.ContentType property

取得與此項目相關聯的內容類型。

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

Syntax

'宣告
Public ReadOnly Property ContentType As SPContentType
    Get
'用途
Dim instance As SPListItem
Dim value As SPContentType

value = instance.ContentType
public SPContentType ContentType { get; }

Property value

Type: Microsoft.SharePoint.SPContentType
表示內容類型的SPContentType物件。

請參閱

參照

SPListItem class

SPListItem members

Microsoft.SharePoint namespace