Command Files

Command files can be used to create new command scripts that perform automation, or to recover previously performed steps.

While HyperWorks Desktop is open it generates a Tcl file named command<#>.tcl on Windows, and command.tcl on Linux. This file is created at the start of a HyperWorks Desktop session if it does not exist. If the file already exists, HyperWorks Desktop adds the commands for the new session to the end of the original file.

Each time HyperWorks Desktop performs an operation that modifies something in the database, such as, create an entity, modify a value, import a model, and so on, the Tcl commands that are used to perform the operation, as well as any subsidiary commands, are written to the command file. These commands are known as HyperMesh Tcl Modify Command. As an example, if you are in the Delete panel and decide to delete all of the elements in the model, the commands written out are:
*createmark elements 1 "all"
*deletemark elements 1