Recording Macros

Not available in Factory Lite and Factory Personal licenses.

If you need to continuously repeat a series of operations or computations in Rulex, you can record these operations as a macro in the development phase. Successive users can then reproduce these operations by launching the specific event, hence hiding the complexity of the underlying flow when necessary.

A practical example of a business application of events is the feedback loop, when you want the results of an operation to be used as the partial import of the same loop. You must then frequently recompute the flow, in the right order, each time new data arrives. A Macro can make this operation easy and fool proof.

Saved macros must be converted to Events to use them.

The recorded events are stored in the Events tab of the Flow Summary and their type will be custom.

Macros can be saved as:

  • Events: the macro is saved only in the current flow, and can be run only within the flow.

  • Source: the macro is saved in the environment, and can be run in any flow contained in the environment. To know more about sources, go to the Flows, Sources and Environments page.


Prerequisites

  • you must have created a flow;

  • you must have computed the operations you want to record in the macro.


Procedure

  1. Click the Record Macro icon in the command bar.

  2. Compute the group of operations you want to record in your macro.

  3. Click the Stop recording icon in the command bar when you have finished your operations.

  4. Select Environment Saved Macro and click Save.

  5. Enter a name and optional description for the macro, then click Ok to save the macro.


Creating Events

If you want to use a macro which has been saved as a resource within your environment, you need to convert it into an event.

This new event can be used in any flow within the same environment.


Procedure - creating events

  1. Click the Record Macro icon in the command bar.

  2. Compute the operations you want to record.

  3. Click the Stop recording icon in the command bar when you have finished your operations.

  4. Select Custom Flow Event and click Save.

  5. Enter a name and optional description for the macro, then click Ok to save the macro.


Procedure - running events

  1. Click the Events icon in the Flow Summary.

  2. Select the event you want to launch from the Macro name list.

  3. Click play to run the event.