[Table of Contents] [docx version]

WordprocessingML Reference Material - Table of Contents

mailMerge (Mail Merge Settings)

This element specifies all of the mail merge information for a document that has been connected to an external data source as part of a mail merge operation.

The document which contains this mail merge data may be of one of two types:

A source document, the document which contains all of the information for the mail merge, and is used in conjunction with an application to connect to an external data source and create one document for each record in that data source.

A merged document, a document which contains all of the information for the mail merge as well as a reference to a single specific record which shall be used to populate the values of all of the merge fields in that document.

The information in this element shall contain all data needed to connect to a data source and populate any merge fields in the document with data from that data source.

[Example: Consider the following WordprocessingML fragment for a document which is part of a mail merge:

<w:mailMerge>

<w:
dataType w:val="spreadsheet" />
<w:query w:val="SELECT * FROM `Sheet1$`" />
<w:dataSource r:id="rId1" />

</w:mailMerge>

Here, the dataType2.14.10) and dataSource2.14.9) elements specify that the given document shall be connected to the external data source referenced by the relationship whose id value is equal to rId1. While connected to the external data source, the document together with a hosting application may extract data from the external data source as specified by the query2.14.26) element. end example]

Parent Elements

settings2.15.1.78)

 

Child Elements

Subclause

activeRecord (Record Currently Displayed In Merged Document)

§2.14.2

addressFieldName (Column Containing E-mail Address)

§2.14.3

checkErrors (Mail Merge Error Reporting Setting)

§2.14.4

connectString (Data Source Connection String)

§2.14.8

dataSource (Data Source File Path)

§2.14.9

dataType (Data Source Type)

§2.14.10

destination (Merged Document Destination)

§2.14.11

doNotSuppressBlankLines (Remove Blank Lines from Merged Documents)

§2.14.12

headerSource (Header Definition File Path)

§2.14.16

linkToQuery (Query Contains Link to External Query File)

§2.14.18

mailAsAttachment (Merged Document To E-Mail Attachment)

§2.14.19

mailSubject (Merged E-mail or Fax Subject Line)

§2.14.21

mainDocumentType (Source Document Type)

§2.14.22

odso (Office Data Source Object Settings)

§2.14.25

query (Query For Data Source Records To Merge)

§2.14.26

viewMergedData (View Merged Data Within Document)

§2.14.36

The following XML Schema fragment defines the contents of this element:

<complexType name="CT_MailMerge">

   <sequence>

   <element name="mainDocumentType" type="CT_MailMergeDocType" minOccurs="1"/>

   <element name="linkToQuery" type="CT_OnOff" minOccurs="0"/>

   <element name="dataType" type="CT_MailMergeDataType" minOccurs="1"/>

   <element name="connectString" type="CT_String" minOccurs="0"/>

   <element name="query" type="CT_String" minOccurs="0"/>

   <element name="dataSource" type="CT_Rel" minOccurs="0"/>

   <element name="headerSource" type="CT_Rel" minOccurs="0"/>

   <element name="doNotSuppressBlankLines" type="CT_OnOff" minOccurs="0"/>

   <element name="destination" type="CT_MailMergeDest" minOccurs="0"/>

   <element name="addressFieldName" type="CT_String" minOccurs="0"/>

   <element name="mailSubject" type="CT_String" minOccurs="0"/>

   <element name="mailAsAttachment" type="CT_OnOff" minOccurs="0"/>

   <element name="viewMergedData" type="CT_OnOff" minOccurs="0"/>

   <element name="activeRecord" type="CT_DecimalNumber" minOccurs="0"/>

   <element name="checkErrors" type="CT_DecimalNumber" minOccurs="0"/>

   <element name="odso" type="CT_Odso" minOccurs="0"/>

   </sequence>

</complexType>