2.1.3 Macros

An AXL Macro is a set of commands that are performed when the Macro is called and logical constructs that control the flow of the Macro. Each command in the Macro is specified by an action and zero or more arguments that modify the meaning of the action. A Macro is called by an object in the application.

A named Macro, that is, a Macro that specifies a name, exists as a database object in the Application. Objects that reference a Macro can specify either the name of a named Macro or a list of inline commands. Macro commands that are specified inline in an object specify an embedded Macro.

Macros are run in one of two contexts, as specified in the next two sections. Errors that occur during the performance of a Macro are stored so that the Macro can handle it with the OnError action. If the Macro clears the error with the ClearMacroError action, the Macro continues as if no error had occurred. If the Macro does not specify an OnError action, the Application can interrupt the flow of the Macro as part of handling the error.