Once you have selected a default macro language (see Selecting a default macro language), you can create a new macro by using the Create Macro dialog, see figure below. The dialog allows you to specify a macro language, enter source code, and save it.
To create a new macro
- Click Tools > Macros > Create Macro on the main menu. The Create Macro dialog opens.
Select a macro language in the Macro Language box.
To ensure the best performance experience, it is strongly suggested that you use the recommended language (Groovy). The icon color next to the language selection reflects performance, (i.e., green for fast, yellow for medium, and red for slow). If the performance is unknown, an info icon appears.
- Enter the source code in the text box.
- Click to test and make sure that the source code works properly.
- Click . The Macro Information dialog opens. Follow the steps described on the Adding a Macro and Its Information page.
- After clicking OK in the Macro Information dialog, the new macro will be saved in the location you have specified in the File text box.