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 MagicDraw main menu. The Create Macro dialog will open, see figure below.
- Select a macro language in the Macro Language box.
- Enter source code in the text box.
- Click to test and make sure that the source code works properly.
- Click . The Macro Information dialog will open. Follow the steps described in Adding a Macro and Its Information.
- 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.