Page 1 of 1

Documents.Open Returns Nothing

Posted: Sun 14. Sep 2014, 16:30
by HardyK
Hi All,

I am controlling PCAN-Explorer from Excel 2010 using VBA. I can instantiate the application and open a project (MyProj.peproj) successfully using the following:

Code: Select all

Sub OpenProject()

   Dim doc

   Set doc = PCANExp.Documents.Open("$(MyDocsDir)\PCAN-Explorer 5\MyProj.peproj",,True)

End Sub
In the snippet above, PCANExp is my instance of PCAN Explorer in VBA.

However, the doc object returned is always Nothing even if the project file was opened correctly. According to the reference documentation, doc should be of type Document if successful. I want to test that doc is not Nothing in order to handle any errors.

<Question>
Does anybody know why doc is Nothing?

Thank you very much.

Re: Documents.Open Returns Nothing

Posted: Mon 15. Sep 2014, 12:09
by PEAK-Support
Please send your request directly to us per e-mail support[at]peak-system.com , including your Serial Number of the PE5.