Ansys Employee


Unfortunately, I didn’t catch the word “parameterized” in the original post, so I didn’t think you were using design points. It gets a lot more complicated to have something run automatically with that. One way is to insert code into a “python code” object in the Outline and send calls up to workbench level to get the design point number. Witihin Mechanical, such as in “Python Code” object:

cmd = ”'
dp = Parameters.GetActiveDesignPoint()
dpNum = dp.Name
ret_dict = ExtAPI.Application.ScriptByName(‘journaling’).ExecuteCommand(cmd, None, ‘dpNum’)
dpNum = ret_dict[‘dpNum’]

You can append this number (as a string) to the filename.

Turn on "Tools > Options  > Mechanical > Connect/Run Python Code Objects when Mechanical is Launched" from workbench project schematic.