Free Support Forum - aspose.com

Set MPDProject Object Variable

I’m having a difficult time setting an object variable to point at an MPDProject. Can you please provide some guidance as to how best to do this? The examples in your documentation and the sample apps fail with the exception ‘Error reading main properties from a database’ being thrown. Obviously, I do have a connection with a SQL Server DB, and I am list all the projects. The problem is that I’m apparently attempting to set the oProj variable imporperly.

Dear Spot,

Thanks for the report.

So
mpd = new MPDDatabase (“Provider=…”);
is working correctly and mpd is not null and has real data about the projects?

Could you send me StackTrace of the exception?

What version of MS Project Server you use? It looks like we have problem with database structure (MSP_PROJECTS table). Microsoft changed all tables from version to version.
One more question. Is it possible to send structure (without data) of your database to project@aspose.com?