Merging Graphics into Word Documents

Written by Allen Wyatt (last updated September 29, 2020)
This tip applies to Word 97, 2000, 2002, and 2003


4

The mail merge feature in Word is extremely powerful, and you can use it to easily create customized versions of documents from information in a data source (such as a Word table, an Excel worksheet, or an Access database). Normally the mail merge feature is used to merge text into a document—items such as a customer name or a part number. There may be times, however, when you want to merge a graphic into your document.

The key to merging graphics is to make sure that you don't try to merge the graphic itself, but to merge a field that "points" to the graphic file. For instance, you might have an Excel worksheet that contains a group of real estate listings. Just make sure you set up your worksheet so that it contains the file address of the graphic you want to merge. Each record in the worksheet should have a complete drive name, path, and file name (in a single column) for the graphic associated with that record. The following is an example of such a file address:

d:\listings\myhouses\smithhouse.jpg

For the purposes of this discussion, let's assume that you named the column PictureLocation. When you create your merge document in Word, you can include a merge field such as this:

{INCLUDEPICTURE "{MERGEFIELD PictureLocation}" \d}

Notice that this is actually two fields within one. It is important to make sure that you include the quote marks, as indicated. When Word merges the document, it replaces the MERGEFIELD field with the data indicated. Thus, the example would become this:

{INCLUDEPICTURE "d:\listings\myhouses\smithhouse.jpg" \d}

The remaining INCLUDEPICTURE field is then translated by Word as a directive to include the noted picture.

It is important to remember that after you perform your merge operation in Word, it may appear that your graphic merge didn't work properly. To speed things up, Word displays the same picture for each of the INCLUDEPICTURE fields. Thus, your merged document will appear as if it contains multiple instances of the same picture. This simply occurs because Word doesn't update the INCLUDEPICTURE field for each record it merges. To force this, simply select the entire document (Ctrl+A) and press F9 or print the merged documents. (Word updates all fields prior to printing.)

WordTips is your source for cost-effective Microsoft Word training. (Microsoft Word is the most popular word processing software in the world.) This tip (1548) applies to Microsoft Word 97, 2000, 2002, and 2003.

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

Making Short Work of Menu Names

If your menu bar has become cluttered due to different add-ins you've added, you can free up space by shortening the menu ...

Discover More

Ensuring Unique Values in a Column

If you want to make sure that only unique values are entered in a particular column, you can use the data validation ...

Discover More

Transposing and Linking

Sometimes it is helpful to look at data that is rotated 90 degrees. Excel allows you to use Paste Special to transpose ...

Discover More

Create Custom Apps with VBA! Discover how to extend the capabilities of Office 365 applications with VBA programming. Written in clear terms and understandable language, the book includes systematic tutorials and contains both intermediate and advanced content for experienced VB developers. Designed to be comprehensive, the book addresses not just one Office application, but the entire Office suite. Check out Mastering VBA for Microsoft Office 365 today!

More WordTips (menu)

Nudging a Graphic

If you need to move a graphic just a little bit in one direction or another, you can do so by using the techniques in ...

Discover More

Hiding Graphics

Do you need a printout where graphics can be turned on and off? This tip provides some concrete ways you can get just ...

Discover More

Default Picture Settings

Place enough pictures, and sooner or later you start wondering if there is a way to set up some default settings for ...

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 0 + 1?

2017-12-20 11:42:38

JT Sullivan

Worked thru this procedure and get the error message: This image can not be displayed. The file may have been removed, renamed or deleted.

Could it be that a .png file is not recognized.? I got the images using the Snit it tool from a pdf file. If so, is there a conversion process to a usable image file?

Thanks


2017-07-18 12:47:28

Scott

What if I am using an XML Mapping within the {IncludePicture} insert above. I can't seem to get this to work. It keeps changing the XML Mapping to just plain text.


2017-01-18 11:54:15

margie

you have to include "around the string" in excel also


2016-12-20 08:47:37

Danny

Hi Allen,
You could use https://document-merge.com/ It's an online service that integrates Excel data into a Word document.
Cheers,
Danny


This Site

Got a version of Word that uses the menu interface (Word 97, Word 2000, Word 2002, or Word 2003)? This site is for you! If you use a later version of Word, visit our WordTips site focusing on the ribbon 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.