With ACT, how can I add a command snippet in the Mechanical tree and import a specific text file in
Pernelle Marone-Hitz
Member, Moderator, Employee Posts: 871
✭✭✭✭
With ACT, how can I add a command snippet in the Mechanical tree and import a specific text file in this command snippet?
Tagged:
0
Answers
-
This can be done by using the following commands (name of text file and directory must be adapted) :
analyse=ExtAPI.DataModel.Project.Model.Analyses[0] IC = analyse.AddCommandSnippet() IC.Name = "Insert Command" file = r"C:\directory\test.txt" IC.ImportTextFile(file)
6