Currently, I am using Jython to develop custom functions in CAMEO. After the simulation is done, the instance table (including results) should be automatically exported to a CSV file. However, the problem is that it is not waiting for the simulation to finish; the table is already exported, so there are no results in the CSV file. Could someone help me solve this issue? The methods I have tried are as follows, but they did not work properly:
- Using a time delay. However, the script always runs the time delay and exports first, then runs the simulation.
- Using a simulation listener. The simulation listener does not work properly for the entire instance table. If I add a listener to each of the instance specifications in the instance table, it always warns me, "There is already a simulation session in progress. Do you want to start a new one?"
I hope I have explained the question clearly. I am looking forward to your answer and help. Thanks.
