You can create reusable macros from sequences of steps in your recipe. These macros can be applied in other locations of the recipe or in other recipes.
- Macros are user-defined sequences of recipe steps that can be referenced independently and parameterized as needed.
- For more information, see Overview of Macros.
In the Recipe panel, select the step or steps that you want to include in your macro.
NOTE: Steps do not have to be consecutive. In the macro, steps are listed in the order in which they appear in the recipe.
- From the context menu next to one of the selected recipe steps, select Create macro....
- Enter a Name and optional Description value.
- The Name of the macro appears in the . Names must be unique.
- Click Next.
Specify any parameters:
NOTE: After you create a macro, you cannot modify its parameters. You can specify non-default parameters in instances that you apply to your recipes.
- Left column: select steps in the macro.
- Middle column: for the selected step, review the values that were specified for the step in the original recipe.
- Right column: as needed, you can parameterize the currently selected value from the middle column. For a selected value, you can choose to create a new parameter or use an existing parameter.
- When you create a new parameter:
- Its data type is determined by the value it is replacing in the original transformation.
- You specify a name, description, and default value for it.
- Parameters that have an empty default value cannot be parameterized at runtime.
- To remove all uses of the parameter from the macro, click Remove all.
- To save your parameter, click Save.
- When you choose to use a parameter:
- Select the parameter to use.
- Specify its value as needed.
- To create the macro and its parameters, click Create.
- An Apply transformation step with the macro's name associated with it is added to your recipe at the selected location.
You can use macros that you have created in other recipe locations. See Apply a Macro.
You can manage macros through the Library page. See Macros Page.