Please Note: This article is written for users of the following Microsoft Word versions: 11, , , , 2010, and 2016. If you are using an earlier version (Word 2003 or earlier), this tip may not work for you. For a version of this tip written specifically for earlier versions of Word, click here: Controlling Date Formats in a Mail Merge.

Controlling Date Formats in a Mail Merge

Written by Allen Wyatt (last updated October 24, 2022)
This tip applies to Word 11, , , , 2010, and 2016


1

David is performing a mail merge using data stored in an Excel workbook. Part of the information being merged is a date. The date is formatted correctly in Excel, but when it is merged into the Word document it loses the formatting. Specifically, it appears as "09-23-2018" but should look like "Sunday, 23 September 2018." David is wondering how to get the formatting on the date that he needs.

There are two things you can try. First, you could check to see what method Word is using to grab the information from the Excel workbook. The default data transfer method is OLE (object linking and embedding), which means that the data is transferred as raw data and Word does it's best to format what it fetches. You can change the data transfer method when you select the Excel workbook in the merge process. Word should display a dialog box that asks how you want to have the data transferred; you should select either a DDE transfer or the Excel by Conversion option.

If you don't see the dialog box, then it means you need to configure Word so that it will present the dialog box. Just exit from the merge and follow these steps:

  1. Display the Word Options dialog box. (In Word 2007 click the Office button and then click Word Options. In Word 2010 or a later version display the File tab of the ribbon and then click Options.)
  2. Click Advanced at the left side of the dialog box.
  3. Scroll through the available options until you come to the General section. (See Figure 1.)
  4. Figure 1. The General section of the Advanced options of the Word Options dialog box.

  5. Make sure the Confirm File Format Conversion On Open check box is selected.
  6. Click on OK.

If all this talk about conversion methods, OLE, DDE, and the rest has your head spinning, take a moment and breathe deeply. You are in luck; there is another way you can get the date format you want without worrying about any method of data transfer. You can add a formatting switch to the merge field used in your document. If you display the field codes (instead of their results), the field usually looks similar to this:

{ mergefield MyDate }

This presumes that the name of the data field, from Excel, is MyDate. You can modify the merge field so that it includes a formatting switch, in this manner:

{ mergefield MyDate \@ "dddd, dd MMMM yyyy" }

The use of the \@ characters indicate that what follows is a pattern for how the date should be formatted. In this case, the date will show similar to "Wednesday, 26 September 2018." Full information on how to put together the date patterns can be found at the Word MVP site, here:

https://wordmvp.com/FAQs/TblsFldsFms/DateFields.htm

WordTips is your source for cost-effective Microsoft Word training. (Microsoft Word is the most popular word processing software in the world.) This tip (6108) applies to Microsoft Word 11, , , , 2010, and 2016. You can find a version of this tip for the older menu interface of Word here: Controlling Date Formats in a Mail Merge.

Author Bio

Allen Wyatt

With more than 50 non-fiction books and numerous magazine articles to his credit, Allen Wyatt is an internationally recognized author. He is president of Sharon Parq Associates, a computer and publishing services company. ...

MORE FROM ALLEN

Searching and Replacing Graphics

Got a bunch of graphics in a document that need replacing? (Perhaps you need to replace an old logo with a new one.) Word ...

Discover More

Adding Quoted Words to an Index

It is not unusual to need to convert one notation in a document into another entirely different notation. For instance, ...

Discover More

Controlling How Word Sorts Text

Word has a very orderly way in which it sorts information, but that orderly method may not meet what you need to have ...

Discover More

Do More in Less Time! Are you ready to harness the full power of Word 2013 to create professional documents? In this comprehensive guide you'll learn the skills and techniques for efficiently building the documents you need for your professional and your personal life. Check out Word 2013 In Depth today!

More WordTips (ribbon)

Merging and Printing a Series of Documents

Do you need to merge and print a number of documents in a particular order? Perhaps the best approach is to record a ...

Discover More

Attaching Specific Files to Mail-Merge E-Mail Messages

Want to add attachments to each e-mail message created in a mail merge? Word doesn't include the capability to do this, ...

Discover More

Formatted Merging

When you use the mail-merge capabilities of Word, the information merged takes on the formatting of your source document, ...

Discover More
Subscribe

FREE SERVICE: Get tips like this every week in WordTips, a free productivity newsletter. Enter your address and click "Subscribe."

View most recent newsletter.

Comments

If you would like to add an image to your comment (not an avatar, but an image to help in making the point of your comment), include the characters [{fig}] (all 7 characters, in the sequence shown) in your comment text. You’ll be prompted to upload your image when you submit the comment. Maximum image size is 6Mpixels. Images larger than 600px wide or 1000px tall will be reduced. Up to three images may be included in a comment. All images are subject to review. Commenting privileges may be curtailed if inappropriate images are posted.

What is three more than 2?

2019-07-31 16:19:25

Les Abeyta

Hello. Thanks for this tip. I've tried the suggestions above but i am still having an issue.

I have a date i've formatted as a short date in my spreadsheet as 9/23/2014.

I've saved my spreadsheet.

I've opened my merge document and merged the specific field into my document. The date (formatted in the spreadsheet as 9/23/2014), comes into my document as 41905 (the unformated date).

I've edited the code to read MERGEFIELD Previous_Recorded_Doc_Date \@ "MM/dd/yyyy" however, i still get 41905.

This is happening randomly with SOME of my documents pulling the same merge field. It works in most but in some it does.

Any idea why?

thank you


This Site

Got a version of Word that uses the ribbon interface (Word 2007 or later)? This site is for you! If you use an earlier version of Word, visit our WordTips site focusing on the menu interface.

Videos
Subscribe

FREE SERVICE: Get tips like this every week in WordTips, a free productivity newsletter. Enter your address and click "Subscribe."

(Your e-mail address is not shared with anyone, ever.)

View the most recent newsletter.