Export (0) Print
Expand All

View.ShowMailItem method

Creates an e-mail message containing the current view.

Namespace:  Microsoft.Office.InfoPath
Assembly:  Microsoft.Office.InfoPath (in Microsoft.Office.InfoPath.dll)

public abstract void ShowMailItem(
	string destinationTo,
	string destinationCC,
	string destinationBcc,
	string subject,
	string body
)

Parameters

destinationTo
Type: System.String

The addresses for the To field of the e-mail message.

destinationCC
Type: System.String

The addresses for the CC field of the e-mail message.

destinationBcc
Type: System.String

The addresses for the BCC field of the e-mail message.

subject
Type: System.String

The Subject field of the e-mail message.

body
Type: System.String

The text for the body of the e-mail message.

ExceptionCondition
ArgumentNullException

The parameters passed to this method are a null reference (Nothing in Visual Basic).

ArgumentException

The parameters passed to this method are not valid. For example, they are of the wrong type or format.

This member can be accessed only by forms running in the same domain as the currently open form, or by forms that have been granted cross-domain permissions.

This type or member can be accessed only from code running in forms opened in Microsoft InfoPath Filler.

In the following example, the ShowMailItem method of the View class is used to create a mail message for the current view.

this.CurrentView,ShowMailItem("someone@example.com", null, null,
    "Sample InfoPath Form", "This is a sample InfoPath form.");
Show:
© 2014 Microsoft