SPAlertCollection.Add method (SPList, SPEventType, SPAlertFrequency)
Deprecated. Use Add(SPList, SPEventType, SPAlertFrequency, SPAlertDeliveryChannels) instead.
Namespace: Microsoft.SharePoint
Assembly: Microsoft.SharePoint (in Microsoft.SharePoint.dll)
Syntax
'Declaration
Public Function Add ( _
list As SPList, _
eventType As SPEventType, _
alertFrequency As SPAlertFrequency _
) As Guid
'Usage
Dim instance As SPAlertCollection
Dim list As SPList
Dim eventType As SPEventType
Dim alertFrequency As SPAlertFrequency
Dim returnValue As Guid
returnValue = instance.Add(list, eventType, _
alertFrequency)
public Guid Add(
SPList list,
SPEventType eventType,
SPAlertFrequency alertFrequency
)
Parameters
list
Type: Microsoft.SharePoint.SPListA Microsoft.SharePoint.SPList object that represents the list to which the alert applies.
eventType
Type: Microsoft.SharePoint.SPEventTypeA Microsoft.SharePoint.SPEventType value that specifies the event type for the alert.
alertFrequency
Type: Microsoft.SharePoint.SPAlertFrequencyA Microsoft.SharePoint.SPAlertFrequency value that specifies the frequency for sending an alert.
Return value
Type: System.Guid
The GUID for the new alert.
Remarks
Warning
If you write new applications, avoid using this deprecated overload, which is maintained only for backward compatibility. If you modify existing applications, you are strongly encouraged to remove any dependency on this feature.
This overload behaves identically to Add(SPList, SPEventType, SPAlertFrequency, SPAlertDeliveryChannels) if Email is passed as its final parameter.