SPEventReceiverDefinitionCollection.Add method (SPEventReceiverType, String)

Creates a remote event receiver definition in the collection that is based on the specified event receiver type and url.

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

Syntax

'Declaration
Public Sub Add ( _
    receiverType As SPEventReceiverType, _
    url As String _
)
'Usage
Dim instance As SPEventReceiverDefinitionCollection
Dim receiverType As SPEventReceiverType
Dim url As String

instance.Add(receiverType, url)
public void Add(
    SPEventReceiverType receiverType,
    string url
)

Parameters

  • url
    Type: System.String

    A string represents the remote event receiver service URL

Remarks

This overload of the Add method adds the new object to the in-memory collection of event receiver definitions, in addition to adding the item to the backing store when the Update method is called on the item.

See also

Reference

SPEventReceiverDefinitionCollection class

SPEventReceiverDefinitionCollection members

Add overload

Microsoft.SharePoint namespace