Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
Kat Kat is offline
external usenet poster
 
Posts: 56
Default Macros across office programs...

Is there any way to write a macro that will open an existing word document
and insert certain fields from my spreadsheet automatically when specific
text is typed into a specific field?
In depth/personal replies are greatly appreciated, and can be sent to kdt AT
chainstarusa DOT com

thanks
kat
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 4,391
Default Macros across office programs...

kat,
You need to look in Automation, the means by which you can control one
application from another. e.g.
Dim MyWord as Word.Application
Set MyWord=New Word.Application
MyWord.Documents.Add
.... etc (but I don't know the Word Object Model)
The easist way to start is record a macro in Word, so you can see what you
need achieve, then transfer this code to Excel, changing the references to
allow for the fact that the code is now in Excel (i.e. so all calls go
through the MyWord, or related, object).
Make sure you .Quit Word and set all object to Nothing, otherwise you will
trouble getting rid of the instances that you create.

Google for "Office Automation", or use that old fashion reference, Your
Local Library.

Nick

"Kat" wrote in message
...
Is there any way to write a macro that will open an existing word document
and insert certain fields from my spreadsheet automatically when specific
text is typed into a specific field?
In depth/personal replies are greatly appreciated, and can be sent to kdt

AT
chainstarusa DOT com

thanks
kat



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Missing programs after downloading open office Spymandalinus Setting up and Configuration of Excel 1 January 11th 08 07:47 PM
Change default document path for all programs in Office Suite? Marian M. Excel Discussion (Misc queries) 4 July 20th 07 05:46 PM
Office 2007 Macros Mr BT Excel Worksheet Functions 1 January 2nd 07 10:56 PM
Excel Programs developed in Office 2000 on Windows 2000 Trooper Excel Discussion (Misc queries) 4 March 12th 05 11:09 PM
Microsoft Office Macros Chandrakant Excel Programming 2 February 17th 04 08:31 PM


All times are GMT +1. The time now is 05:09 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"