共用方式為


SPEventReceiverDefinitionCollection.EventReceiverDefinitionExist method

傳回指定集合中是否存在指定的Guid事件接收器定義Boolean變數。

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

Syntax

'宣告
Public Function EventReceiverDefinitionExist ( _
    eventReceiverId As Guid _
) As Boolean
'用途
Dim instance As SPEventReceiverDefinitionCollection
Dim eventReceiverId As Guid
Dim returnValue As Boolean

returnValue = instance.EventReceiverDefinitionExist(eventReceiverId)
public bool EventReceiverDefinitionExist(
    Guid eventReceiverId
)

參數

傳回值

Type: System.Boolean
true如果事件接收器定義存在於集合中。否則, false。

備註

例如, ItemAdded(SPItemEventProperties)SPEventReceiverDefinition方法可重複使用。可以有一對多與之間的對應事件接收者可以產生事件的SharePoint Foundation物件。

請參閱

參照

SPEventReceiverDefinitionCollection class

SPEventReceiverDefinitionCollection members

Microsoft.SharePoint namespace

其他資源

事件登錄