How to export Ansys Viewer Files (.avz) for each Design Point?
Pernelle Marone-Hitz
Member, Moderator, Employee Posts: 871
✭✭✭✭
in Structures
How to export ansys viewer files from mechanical when mechanical is executed as part of a design point run? Export should be done to user files directory and the file name should include a reference to the design point it was generated from.
Tagged:
0
Answers
-
import wbjn import os userdirectory=wbjn.ExecuteCommand(ExtAPI,'returnValue(GetUserFilesDirectory())') results=ExtAPI.DataModel.GetObjectsByType(DataModelObjectCategory.Result) dpn = wbjn.ExecuteCommand(ExtAPI,"returnValue(a+Parameters.GetActiveDesignPoint().Name)",a="DP") for result in results: result.Activate() mvm=ExtAPI.Graphics.ModelViewManager avzFilename=os.path.join(userdirectory,'{}{}.avz'.format(result.Name,dpn)) mvm.Capture3DImage(avzFilename)
1