Effect of \*MERGEFORMAT When Updating Link to Excel Sheet

ID: Q86353


The information in this article applies to:
  • Microsoft Word for Windows, versions 1.0, 1.1, 1.1a, 2.0, 2.0a, 2.0a-CD, 2.0b, 2.0c, 6.0, 6.0a, 6.0c
  • Microsoft Word for Windows 95, version 7.0


SUMMARY

If you update the link to a Microsoft Excel for Windows spreadsheet in your Microsoft Word for Windows document, the following formatting may be affected:

  • Font and Point Size


  • Cell Borders


  • Cell Dimensions


Whether or not changes in the above formatting occur depends on the presence of the \*MERGEFORMAT switch in the LINK or DDE field. This formatting is also affected by whether you modify the linked information from within Word for Windows or from within Excel for Windows.


MORE INFORMATION

If you link an Excel spreadsheet to a Word document, a LINK field (DDE field in Word 1.x) that references the spreadsheet in Excel will be inserted in your document. If you press F9 to update the results of this field, Word will insert a new copy of the spreadsheet.

If you use the \*MERGEFORMAT switch in a field, the field result will retains the exact formatting of the previous result when you update the field. For example, if your LINK field contains the \*MERGEFORMAT switch and you edit the data, the font, and the border and cell dimensions in your Excel spreadsheet, when you update the LINK field in Word, only the data will be changed in the LINK field results. The \*MERGEFORMAT switch prevents the formatting of the font and the border and cell dimensions from updating. If your LINK field does not contain the \*MERGEFORMAT switch, formatting of the font and the border and cell dimensions, as well as the data, will be updated to reflect changes made to the Excel spreadsheet when you update the LINK field.

Similarly, if you modify the data and formatting of the spreadsheet by changing the results of the LINK field in Word, only the data will be refreshed when you press F9 to update the field results if the field contains the \*MERGEFORMAT switch. The data AND formatting will be refreshed when you press F9 if the field does not contain the \*MERGEFORMAT switch. Therefore, if you want to retain formatting applied to the linked spreadsheet in Word, be sure the field contains the \*MERGEFORMAT switch.

Note: You cannot prevent your Excel chart from resizing each time you update its LINK field in Word by adding or removing the MERGEFORMAT switch. The chart resizes regardless of the presence or absence of the MERGEFORMAT switch.


REFERENCES

"Microsoft Word for Windows User's Guide," version 2.0, pages 748, 756

"Microsoft Word for Windows User's Reference," version 1.x, pages 94-95

Additional query words: 1.0 1.10a 2.0 6.0 winword 7.0 word95 word6 ddeauto dynamic data exchange winword2 word7

Keywords : kbfield
Version : WINDOWS:1.0,1.1,1.1a,2.0,2.0a,2.0a-CD,2.0b,2.0c,6.0,6.0a,6.0c,7.0
Platform : WINDOWS
Issue type :


Last Reviewed: December 23, 1999
© 2000 Microsoft Corporation. All rights reserved. Terms of Use.