Microsoft Office Online
Sign in to My Office Online (What's this?) | Sign in

 
 
Microsoft Office Word
Search
Search
 
Check for updates: (c) Microsoft
Office downloads
 
 
 
Warning: You are viewing this page with an unsupported Web browser. This Web site works best with Microsoft Internet Explorer 6.0 or later, Firefox 1.5, or Netscape Navigator 8.0 or later. Learn more about supported browsers.

Email this linkEmail this link Printer-Friendly VersionPrinter-Friendly Version Bookmark and ShareShare
Field codes: NextIf field
 

{ NEXTIF Expression1 Operator Expression2 }

Compares two expressions. If the comparison is true, Microsoft Word merges the next data record (data record: A complete set of related information that corresponds to one row of information in the data source. All information about one client in a client mailing list is an example of a data record.) into the current merge document. Merge fields that follow the NEXTIF field (field: A set of codes that instructs Microsoft Word to insert text, graphics, page numbers, and other material into a document automatically. For example, the DATE field inserts the current date.) in the main document (main document: In a mail-merge operation in Word, the document that contains the text and graphics that are the same for each version of the merged document, for example, the return address or salutation in a form letter.) are replaced by values from the next data record rather than the current data record. If the comparison is false, Word merges the next data record into a new merge document.

You may find the SKIPIF field used in documents created in previous versions of Word, but don't use the SKIPIF field in the current version of Word. You can select data records more easily by using the Mail Merge Recipients dialog box, which appears when you connect to a data source (data source: A file that contains the information to be merged into a document. For example, the list of names and addresses you want to use in a mail merge. You must connect to the data source before you can use the information in it.) during a mail merge.

Note  NEXTIF fields cannot be used in footnotes, endnotes, annotations, headers, footers, or data sources. The NEXTIF field cannot be nested within any field.

advertisement