Objects Library

R

Red

Hi ya,

Not sure how to word this as I'm a bit of a novice but I've written code to
extract data to Excel from Project. The Excel 10 Object Library must
therefore be referenced in the Tools/References menu. However on some
computers when Object Library is set and the application then closed it
loses the settings resulting in a error.

I'd be grateful if someone could explain why this happens and how to make
sure the reference is set when Project is launched.

Ta in advance.
 
J

Jan De Messemaeker

Hi,

The Reference must be set in the file the modules reside in
If the modules reside in Global.mpt you have to set the reference with
ProjectGlobal selected in the project explorer, and vice versa when the
modules reside in a file.

To add a reference, here's an example

ProjectGlobal.ThisProject.VBProject.Reference.Addfromfile("MSOUTL8.OLB")
The exact name and location of the OLB file are displayed when you click the
refernce in the tools, references list.

HTH

--
Jan De Messemaeker
Microsoft Project Most Valuable Professional
Project Management Consultancy
Prom+ade BVBA
32-495-300 620
 

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