0 out of 1 rated this helpful - Rate this topic

SPUtility.SendEmail Method (SPWeb, StringDictionary, String, Boolean)

Windows SharePoint Services 3
Sends the e-mail message to the specified address.

Namespace: Microsoft.SharePoint.Utilities
Assembly: Microsoft.SharePoint (in microsoft.sharepoint.dll)
public static bool SendEmail (
	SPWeb web,
	StringDictionary messageHeaders,
	string messageBody,
	bool appendFooter
)

Parameters

web

A Microsoft.SharePoint.SPWeb object that represents the site.

messageHeaders

Name-value pairs for header fields.

messageBody

Sends the e-mail message to the specified address.

appendFooter

true if there is a footer to be appended to the e-mail; otherwise false.

Return Value

If true, the e-mail is sent successfully; otherwise, false.
Exception type Condition

ArgumentNullException

Web or SPWeb.CurrentUser is null.

The value that specifies the sender of the e-mail message is populated from the global configuration context, if it is not supplied through the HttpContext object.

Did you find this helpful?
(1500 characters remaining)
Community Content Add
Annotations FAQ