Edit

Share via


EmailAdapterObject Interface

Definition

Represents the data adapter for submitting form information in e-mail by using Microsoft Office Outlook.

public interface class EmailAdapterObject : Microsoft::Office::Interop::InfoPath::SemiTrust::EmailAdapter
[System.Runtime.InteropServices.Guid("096cd5d7-0786-11d1-95fa-0080c78ee3bb")]
public interface EmailAdapterObject : Microsoft.Office.Interop.InfoPath.SemiTrust.EmailAdapter
type EmailAdapterObject = interface
    interface EmailAdapter
Public Interface EmailAdapterObject
Implements EmailAdapter
Attributes
Implements

Examples

The following example retrieves an EmailAdapter object that represents the data connection named "Email Submit" from the DataAdaptersCollection object, sets the To and Subject property, and then submits the current form to the data connection.

<span class="label">EmailAdapterObject</span> myEmailAdapter = 
   ((<span class="label">EmailAdapterObject</span>)thisXDocument.DataAdapters["Email Submit"]);
myEmailAdapter.To = "list@example.com";
myEmailAdapter.Subject = "Status Report";
myEmailAdapter.Submit();
<span class="label">Dim </span>myEmailAdapter As <span class="label">EmailAdapterObject</span>  = _
   DirectCast(thisXDocument.DataAdapters("Email Submit"), _
<span class="label">EmailAdapterObject</span>);
myEmailAdapter.To = "list@example.com"
myEmailAdapter.Subject = "Status Report"
myEmailAdapter.Submit()

Remarks

This type is a wrapper for a coclass that is required by managed code for COM interoperability. Use this type to access the members of the COM interface implemented by this coclass. For information about the COM interface, including a link to descriptions of its members, seeEmailAdapter.

Use the Item[Object] property of the DataAdaptersCollection collection to return an EmailAdapterObject object. Before you can access and use the properties and methods of the EmailAdapterObject, you must cast the object returned from the DataAdaptersCollection to the EmailAdapterObject type.

Properties

AttachmentFileName

Gets or sets the file name to be used for the current form when the form is attached to the e-mail message of an EmailAdapterObject object.

(Inherited from EmailAdapter)
AttachmentType

Gets or sets the type of file to be attached to the e-mail message submitted with an EmailAdapter object.

(Inherited from EmailAdapter)
BCC

Gets or sets the BCC recipients of an e-mail message associated with an EmailAdapterObject object.

(Inherited from EmailAdapter)
CC

Gets or sets the carbon copy (CC) recipients for the e-mail message associated with an EmailAdapterObject object.

(Inherited from EmailAdapter)
Intro

Gets or sets the introduction in the body of the e-mail message for an EmailAdapterObject object.

(Inherited from EmailAdapter)
Name

Gets the name of the EmailAdapterObject object.

(Inherited from EmailAdapter)
QueryAllowed

Gets a value that always returns false, corresponding to the queryAllowed attribute in the form definition file (.xsf).

(Inherited from EmailAdapter)
Subject

Gets or sets the subject of the e-mail message associated with the specified EmailAdapterObject object.

(Inherited from EmailAdapter)
SubmitAllowed

Gets a value that is always true, corresponding to the submitAllowed attribute in the form definition file (.xsf).

(Inherited from EmailAdapter)
To

Gets or sets the recipients for the e-mail message associated with a specified EmailAdapterObject object.

(Inherited from EmailAdapter)

Methods

Query()

The Query method is available for the EmailAdapterObject object but, because the EmailAdapter object is available for submitting data only, the method will always generate a run-time error when it is called.

(Inherited from EmailAdapter)
Submit()

Executes the submit operation on the associated adapter.

(Inherited from EmailAdapter)
SubmitData(IXMLDOMNode)

Submits the specified DOM element or DOM document to a data adapter.

(Inherited from EmailAdapter)

Applies to