共用方式為


SPAlert.Item property

取得或設定清單項目或警示所套用的文件。

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

Syntax

'宣告
Public Property Item As SPListItem
    Get
    Set
'用途
Dim instance As SPAlert
Dim value As SPListItem

value = instance.Item

instance.Item = value
public SPListItem Item { get; set; }

Property value

Type: Microsoft.SharePoint.SPListItem
SPListItem 物件,表示清單項目或文件。

備註

如果**AlertType()**屬性包含Item, Item屬性是必要的。

這個屬性會在下列情況下,擲回SPException

  • 如果之前設定AlertType屬性設定。

  • 如果變更後會呼叫Update方法。

  • 如果用於警示,套用至清單或文件庫。

如果AlertType屬性不包含Item ,呼叫Update方法時, Item屬性會包含a null reference (Nothing in Visual Basic) 。

請參閱

參照

SPAlert class

SPAlert members

Microsoft.SharePoint namespace