Problem Opening MPP(xml) using C#

M

Mohan Kumar

using the following code,i opening the xml using MSProject.but it does not
work?
what is wrong in my code?

please help me on this.

Thanks in advance.

string xmlfile = @"D:\test.xml";
Microsoft.Office.Interop.MSProject.ApplicationClass app =
new ApplicationClass();
object oMissing = Type.Missing;
bool bOpen = app.FileOpen(xmlfile, true,
PjMergeType.pjDoNotMerge, oMissing, oMissing, oMissing, oMissing, oMissing,
oMissing, oMissing, oMissing, PjPoolOpen.pjDoNotOpenPool, oMissing, oMissing,
oMissing, oMissing);
 
A

Abhijit

in case you are still struggling, you need to speficy the formatID as
"MSProject.XML"
i.e
FileOpen(mlfile, true, PjMergeType.pjDoNotMerge, oMissing, oMissing,
oMissing, oMissing, oMissing, oMissing,"MSProject.XML".........
 
Top