MailMergeFields.AddNext Method

Word Developer Reference

Adds a NEXT field to a mail merge main document. Returns a MailMergeField object.

Syntax

expression.AddNext(Range)

expression   Required. A variable that represents a MailMergeFields collection.

Parameters

Name Required/Optional Data Type Description
Range Required Range object The location for the NEXT field.

Return Value
MailMergeField

Remarks

A NEXT field advances to the next record so that data from more than one record can be merged into the same merge document (for example, a sheet of mailing labels).

Example

This example adds a NEXT field after the third MERGEFIELD field in Main.doc.

Visual Basic for Applications
  Documents("Main.doc").MailMerge.Fields(3).Select
Selection.Collapse Direction:=wdCollapseEnd
Documents("Main.doc").MailMerge.Fields.AddNext _
    Range:=Selection.Range

See Also