Quantcast
Channel: Microsoft Dynamics NAV Forum - Recent Threads
Viewing all articles
Browse latest Browse all 29197

Dynamics NAV DotNet Interopability MS Project

$
0
0

Hello there.

I'm currently trying to read an .mpp file from Dynamics NAV 2016 using .NET variables but experience problems while opening the .mpp file. I receive the error message: "The argument value is not valid."
I would be very grateful if someone could provide more details about how to do this.

 I have assigned the variables:
***************************************
AppProject : DotNet Microsoft.Office.Interop.MSProject.ApplicationClass
PjPoolOpen : DotNet Microsoft.Office.Interop.MSProject.PjPoolOpen
sPath : Text C:\Temp\test.mpp

So, I'm insantiating the AppProject and the PjPoolOpen
***********************************************************
AppProject := AppProject.ApplicationClass;
PjPoolOpen := PjPoolOpen.PjPoolReadOnly;

And then I'm trying to open the file:
**************************************
AppProject.FileOpenEx(
  sPath,
  '',
  '',
  '',
  '',
  '',
  '',
  '',
  '',
  '',
  '',
  '',
  PjPoolOpen,
  '',
  '',
  '',
  '',
  '')

Thanks in advance!

Best regards,
Sebastien


Viewing all articles
Browse latest Browse all 29197

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>