Automating a Paste from Excel to Word for WindowsLast reviewed: November 4, 1994Article ID: Q57637 |
The information in this article applies to:
SUMMARYThe information below describes a macro technique that makes it possible to automatically paste data from Microsoft Excel into Word for Windows.
MORE INFORMATIONThe following points are assumed in the sample macro:
The macro code is as follows:
A1: title A2: =SELECT(!area1) A3: =COPY() A4: =EXEC("c:\winword\winword.exe "&!B1,3) A5: =SEND.KEYS("%ep%fx~") A6: =RETURN()Cell B1 contains the path and filename of the Word for Windows document (for example, the text "C:\WINWORD\TEST.DOC"). The Microsoft Excel data is pasted into Word for Windows as a table. For more information, query on the following words:
SEND.KEYS and data and Excel and pasted and table |
KBCategory: kbinterop
© 1998 Microsoft Corporation. All rights reserved. Terms of Use. |