Looking for a description of the Project 2003 object library.

A

Anatoliy

I need to use MS Project 2003 interface to export/import my schedule
application written in C++ to an MS Project file. Any suggestions where to
find a description of the MS Project's exposed API (additionally to the text
of the type library SPRJ.OLB itself) and/or code samples will be greatly
appreciated.
 
A

Anatoliy

Hi, Jack. Thanks for very useful reference to the VBA help. I just installed
it on my PC. It has all necessary information about the Project's API. It
seems though that the MS Project provides a wrapper for its COM component to
simplify using the API in a VB application. I need to operate with the
component from a C++ code. So I have to work directly with the type library.
It would be helpful to have some information about using the Project's API in
a C++ code. But the VBA help is very useful anyway. Thanks.
 
R

Rod Gill

If at all possible use VB to talk to any Office application. VB is much
quicker to write the necessary code and easier and quicker to debug. C++
would possibly take more than twice as long as using VB.
 
A

Anatoliy

Thanks Rod. I finally might have to do so. Our software is written in C++
and I would prefer to use C++ to integrate with MS Project. When trying to do
it I ran into another problem: the MFC generated wrapper classes for
MSPRJ.OLB don't even compile. This approach works for Excel, as I tested. Is
something wrong with the type library? Why all MSDN articles abut C++ Office
automation avoid mentioning MS Project among other office applications? When
I was trying to use the type library via Import, the project was too big for
the compiler. Who has any experience with all this pleasure? Thanks in
advance for any comments.
 
B

Brian K - Project MVP

Anatoliy said:
Thanks Rod. I finally might have to do so. Our software is written in C++
and I would prefer to use C++ to integrate with MS Project. When trying to
do
it I ran into another problem: the MFC generated wrapper classes for
MSPRJ.OLB don't even compile. This approach works for Excel, as I tested.
Is
something wrong with the type library? Why all MSDN articles abut C++
Office
automation avoid mentioning MS Project among other office applications?
When
I was trying to use the type library via Import, the project was too big
for
the compiler. Who has any experience with all this pleasure? Thanks in
advance for any comments.

So write all your code that deals with Project in VB and compile it into a
dll and then make your calls to your dll using your C application. Just a
thought.
 
R

Rod Gill

The object library works fine from other office apps and vb so I suspect C++
is the problem. Brian is right, code in vb all the interfaces, compile as a
separate dll and call from C++. Probably save you several weeks!!
 

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