

For example, if you selectĪnd apply bold formatting, Word retains the bold formatting when the field is updated when the author name changes. To quote from Help, the MERGEFORMAT switch applies “theįormatting of the previous result to the new result. In Word 2007, select the Insert tab on the Ribbon, click Quick Parts in the Text. Using (or not using) the MergeFormat switch Required Editions Place your cursor where you want to insert a merge field. IF fields can be made more powerful than this, because you can nestįor example, you can create a field with logic such as: “IfĬondition 1 is met, then if Condition 2 is also met, displayīoth conditions are met, display Result 1 ” A real example mightĪgain, all of the curly brackets must be inserted by pressing Ctrl+F9. Where the curly brackets represent field braces, which you must insertīy pressing Ctrl+F9 (you can't type them).
.png)
#Mail merge in word series#
Insert different series of boilerplate files, depending on certainĬonditions stored in the data file, which could be used, for example, inĪt its simplest, an IF field works as follows: If a condition is metĭisplay one result, otherwise display another. At a more sophisticated level they can be used to Main body of a letter or other mail merge document for things likeĭepending on gender. Why and HowĪlmost any mail merge will work better if you use IF fields, as theįrequently used scenarios discussed below attempt to illustrate.Īt their simplest, they can be used to suppress unwanted spaces andĬommas in an address, if a field is blank.
#Mail merge in word code#
You should now see the actual field code for the field, which should look something like Īdding Font Formatting to Mail Merge Fields When you click on that, Start Mail Merge is the third option from the left side of your screen. Or, right-click on the field and choose the Toggle Field Code option. Press + F9 to reveal the field coding.

Select the mail merge field, such as Company, as shown in this example.Try this formatting fix on letters, emails, and other documents that link to mail merge data from Excel, Word, or Access. How can you apply custom text or date formats to a mail merge field to accurately display the formatted text in a Word mail merge main document? The solution is to add a mail merge switch to the mail merge code or MERGEFIELD instruction. Fortunately, there are options to customize the format of date or text fields without creating multiple versions in the original data source. Or, perhaps you want to change the display of date merge fields, especially if the original date is not merging with the correct format. For instance, a text field such as a project title or vendor name may be used in a variety of documents in various formats such as UPPER CASE or lower case. Whether you are bringing data in from an Excel worksheet, an Access database, or a Word table, you may sometimes want the flexibility of applying different or consistent formatting to text or date fields as you reference them throughout your mail merge documents. Working with the mail merge feature in Microsoft Word is a time-saving option to create repetitive, custom-tailored documents from letters to contracts to emails to labels and more.
