AnsweredAssumed Answered

Run external macro from PDM task - object disconected from client

Question asked by Sylwester Kowalski on Jun 6, 2019
Latest reply on Jul 31, 2019 by Sylwester Kowalski

Hello,

 

In PDM task a have script witch makes the following steps:

- get part path from PDM - FilePath = "<Filepath>"

- open this part -  Set Model = swApp.OpenDoc6(FilePath, 1, 0, "", errors, wornings)

- run external macro - boolstatus = swApp.RunMacro2(macroPath, moduleName, subName, swRunMacroUnloadAfterRun, runMacroError)

 

I used to this way in several other cases without problem but now I have a few:

This macro refers to a few model: mirror parent, drawings etc and I think that is a problem.

 

Example error:

 

Do I have to change referens to models/opbjects in code when I run it from PDM task?

 

Thanks,

Sylwester

Outcomes