Creating and Running Methods in Models
You can use the method editor capabilities in the Application Builder to create methods that you can run to automate or extend operations in the Model Builder tree such as creating a geometry or running some special solver sequence. To add a method, go to the Developer ribbon and click New Method () in the Create Methods section. In the New Method window, specify a method name in the Name field and click OK. The Application Builder then opens, and the new model method appears under Methods () in the Application Builder tree. You can then record or write code for the method in the model editor window. See the Application Builder documentation for more information about methods. By default, the Show in Model Builder check box is selected in the settings for the Method node. All methods with that check box selected appear under Run Method in the Model Builder.
To run a method in the Model Builder, click Run Method () in the Run Methods section and choose the method to run. The Model Builder tree is updated according to the changes that the method includes. Click Stop () to stop a running method to debug it, for example. You can open the Debug Log window from the Windows menu to view debug information. You can also add breakpoints for debugging purposes. You can also click Run Method Call () to run a method call in a Method Call node (see Method Calls below). Method calls support input arguments for the model methods, so that you, for example, can use two instances of the same model method with different input values. Model methods with inputs are not available for Run Method. For methods without inputs, running a method directly or through a method call is equivalent.
See the Introduction to Application Builder for an example of a model method and the Application Builder Reference Manual for information about the Model Method node and about creating and debugging methods in general.