Click or drag to resize
ISubscriptionServiceSubscribe Method (ContactInfo, NewsletterInfo, SubscribeSettings)
Subscribes contact to given newsletter. Removes the email from unsubscription list for given newsletter. Whether or not email is removed from "unsubscribe from all" list can be specified in subscribeSettings parameter. subscribeSettings parameter specifies whether confirmation email will be sent and if subscription should be approved immediately.

Namespace: CMS.Newsletters
Assembly: CMS.Newsletters (in CMS.Newsletters.dll) Version: 11.0.0
Syntax
C#
void Subscribe(
	ContactInfo contact,
	NewsletterInfo newsletter,
	SubscribeSettings subscribeSettings
)

Parameters

contact
Type: CMS.ContactManagementContactInfo
ContactInfo object
newsletter
Type: CMS.NewslettersNewsletterInfo
NewsletterInfo object
subscribeSettings
Type: CMS.NewslettersSubscribeSettings
Options defining additional behavior of this method. Cannot be null
Exceptions
ExceptionCondition
ArgumentNullExceptionEither contact, newsletter, or subscribeSettings is null.
Remarks
If the subscription is approved, performs logging of the subscription logging activity.
See Also