Now - what's wrong with THIS code?

K

Kris Rudin

OK, still struggling with VBA in Project.

I had this code in the VBA for a local project:

'create new project
Dim newProj As Project
Set newProj = CreateObject("MSProject.Project")

Worked fine.

Copied it into the Enterprise Global code, and when run from there it throws
this error:

"Error 403: Class does not support automation or does not support expected
interface"

On the line where I actually create the project object.

I did some googling and found many references to MDAC versions, and one item
in the KB at MS which said to use late binding. So I tried:
'create new project
Dim newProj As Object
Set newProj = CreateObject("MSProject.Project")

But it threw the same error on the same line.

Any ideas?

Thanks,
Kris
 

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