• Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint
Share this Page URL
Help

9. Advanced Word Hacks > 84. Automate Word from Other Applications

Automate Word from Other Applications

Many of the same things VBA makes possible from within Word can be done from another application by using COM automation.

Word, like the rest of the Office suite, supports COM automation. COM (Component Object Model) is a technology developed by Microsoft that allows one application to control another without any regard to the differences in the programming languages used by either application. As long as both applications “speak” COM, they’ll get along just fine.

Think about using an ATM. Each machine might be a different size, and sometimes the buttons are in different places, but you don’t really care what the machine looks like, or how it works inside, as long as you can put in your card and get money. A COM server is like the ATM machine: as long as you (the application, or client) make a valid request for money (the service), the machine clicks and whirrs and spits out the cash. The client requesting the service cares only that the server respond in terms that it can use and understand.


PREVIEW

                                                                          

Not a subscriber?

Start A Free Trial


  
  • Creative Edge
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint