Microsoft Word and Excel 11.0 Object Library

E

ekreider

I have Office 2000. I have written a progam to run in Excel and to open a
Word document and print the Word document with the Excel spreadsheet. The
program works fine on my computer (it has XP Professtional), but when I try
to use it the same program on 2 other computers ( 1. Windows 2000
Professtional, 2. XP Professtional) the program will not run correctly. The
only difference I can see is on my computer I have Microsoft Word and Excel
11.0 Object Library and the others do not. Can anyone help me fine the
libraies that I need?
 
B

Bob Phillips

Use late-binding

Dim WordApp As Object
Dim WordDoc As Object

Set WordApp = CreateObject("Word.Application")
WordApp.Visible = True

Set WordDoc = WordApp.Documens.Open(filename)

'then work on WordDoc

Set WordDoc = Nothing
Set WordApp = Nothing

--
---
HTH

Bob


(there's no email, no snail mail, but somewhere should be gmail in my addy)
 
E

ekreider

Bob,

Thank you. I had had the late binding reference in the macro before and took
it out. This got the program to run correctly.

Thanks,

ekreider
 
E

ekreider

papou,

Thank you. I had had the late binding in the macro and took it out. This
correct my problem everything ok now. I used your support reference an
printed out the early and late bindings.

Thanks,

ekreider
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top