I've been having issues with using starting options in 14.0 and forwards. It worked fine in 13.2 (With different file paths of course). I've been trying to use this:
"C:\Program Files\Siemens\Tecnomatix Plant Simulation 14.1\PlantSimulation14_1.exe" -TrustModels -f C:\Temp\TrustModels\ExampleModel.spp -e C:\Temp\TrustModels\StartingCode
The code in startingCode loads libraries into ExampleModel and then tries to use writeObject methods to save certain objects. This results in an error for me.
Due to these problems, I've moved towards using the COM interface instead to accomplish what I want to do.
When using the COM interface, is there a possibility to recreate the -NoMessageBox starting option?
I've attached a package with the model, source code and link to Plant Simulation.
Solved! Go to Solution.
I've checked your issue.
To me it is not clear, why Psi doesn't accept any kind of trustedModels settings
when using startup code.
In any way
if you place the startup code in an autoexec method in the root library
would this workaround -as a start- suit you ?
In Model Settings you have 'Prohibit access to the computer' turned on. You have to turn it off.
The start option '-TrustModels' just trusts models which have this option turned off, it doesn't turns off this setting.
For the COM-Interface you could call the function SetNoMessageBox with the argument false.
Edit: See the correct answer from Martin below...
I examined your problem and found out several different issues.
In short words:
Did you like the answer? Then click the Thumbs Up button.
Did the answer solve your problem? Then accept the answer as solution
Thank you very much for both your answers!
Glad to see that there's a fix coming for the -e issue.
Also, @RalfTobel, the SetNoMessageBox function is undocumented. Would it be possible to add it to the help files?
Sure, we will add it to the documentation.