Macros

A macro is a sequence of instructions that become automatic when called.

You can start macros manually in ARIS Architect or automatically in ARIS Architect and ARIS. To start macros automatically, you can define that a macro is started when a certain event occurs.

ARIS is supplied with numerous standard scripts. Authorized ARIS users can analyze and process data using scripts that you provide. The package and license that you have purchased will determine the range of macros available to you.

If you have the ARIS Enterprise Admin license privilege and the Script administrator function privilege, you can perform basic report management in ARIS Administration. If you are familiar with the JavaScript and ARIS Script programming languages, you can edit or write your own scrips in ARIS Architect.

To manage macros in ARIS Administration, click Application launcher Application launcher > Administration Administration > Configuration Configuration > Evaluation and select Macros.

All scripts are organized in a clear structure using categories.

Categories

You can Add template Create a category if you have no category selected.

Use categories to organize your scripts in a clear structure.

  1. Click Application launcher Application launcher > Administration Administration > Configuration Configuration > Evaluations and select Macros.

  2. Click Add template Create category.

  3. Enter the name of the new category and click Apply.

The category is displayed only in the current language.

To display the category in multiple interface languages, you must rename the category in each language. If you do not specify a category in a particular language, the category is displayed in English.

If you select a category, you can do the following:

Rename Rename a category

You can change the name of a category or specify the name in a different language. You cannot change the name of the Standard category.

  1. Click Application launcher Application launcher > Administration Administration > Configuration Configuration > Evaluations and select Macros.

  2. Select the category and click Rename Rename.

  3. Select the related language.

  4. Enter the name in the selected language and click Apply.

The category is renamed in the current language.

Delete Delete a category

You can delete a category and all the scripts that it contains. Software AG recommends that you first export the scripts in order to have backup files.

  1. Click Application launcher Application launcher > Administration Administration > Configuration Configuration > Evaluations and select Macros.

  2. Select the category that you want to delete. You cannot delete the Standard category.

  3. Click Delete Delete.

  4. Click Delete to confirm.

The category and all scripts that it contains are deleted.

Import Import a script

You can import scripts from export files or import common files that a script uses during runtime. This enables you to provide scripts from another tenant or import scripts from a previous version.

  1. Click Application launcher Application launcher > Administration Administration > Configuration Configuration > Evaluations and select Macros.

  2. Click the category into which you want to import the script.

  3. Import Import.

  4. Select the related import file and click Open.

  5. If the script already exists in a category, you must confirm in order to import a copy into the selected category.

  6. If the script executes imported common files during runtime, you can enable the required file and confirm the import of the file. Otherwise, the current common file on the tenant is used.

The script is imported.

Add template Create macro

Create your own event-triggered macro that automatically starts a report or a semantic check.

  1. Click Application launcher Application launcher > Administration Administration > Configuration Configuration > Evaluations and select Macros.

  2. Click the category to which you want to add the macro or create a new category.

  3. Click Add template Create Macro.

  4. Select the language in which you want to edit the text fields.

  5. Specify the entries in all required languages. Name and Description are especially important. Overwrite the name, subject, author, company, or description, as required.

  6. Select the next language, if required, and edit the text fields in turn.

  7. If required, disable the Available to users check box if you created a macro but have not checked it yet. Scripts can still be edited in the Script Editor (ARIS Architect).

  8. Click Context > Add template Add event and add the event that will automatically start the report or semantic check.

    The added event defines the context for which the macro can be started. You cannot add types, such as model types, but you can activate Include derived types. This makes sense if you want the macro to be started, for example, for a model of a derived model type that is not listed in the added model types.

  9. Click Content and in the Content field select The macro runs a report or The macro runs a semantic check, as required.

    If you select User-defined macro (available only in ARIS Architect), you can specify basic properties, but you can write the script only in ARIS Architect.

  10. Select the required report or semantic check profile.

  11. Click Output, enable Generate output file, and select the file types if required.

  12. Click Apply.

The macro is available.

If you restrict access for execution to specific users, make sure that these restrictions exactly match the ones of the report or the semantic check profile to be started by this macro.

When you select a macro, you can do the following:

Edit Edit macro properties

Duplicate Duplicate the macro script

Duplicate standard scripts and files to prevent your changes from being lost. During a system update, all standard scripts and files are automatically overwritten to provide you with the newest features.

  1. Click Application launcher Application launcher > Administration Administration > Configuration Configuration > Evaluations and select Macros.

  2. Click the category in which you keep the script.

  3. Select the related script and click Duplicate Duplicate.

The script has been duplicated.

You can modify the duplicated script. The duplicated script will not be overwritten during an ARIS update because it has a new GUID.

Delete Delete the macro script

You can delete scripts that you no longer require, such asa report scrips. If you export the scripts first, you can make them available again at any time.

  1. Click Application launcher Application launcher > Administration Administration > Configuration Configuration > Evaluations and select Macros.

  2. Click the category in which you keep the script.

  3. Select the script and click Delete Delete.

  4. Click Delete to confirm.

The script is no longer available on the tenant.

Export Export the macro script

You can save scripts as export files if you want to store different versions or to make scripts available on multiple tenants.

  1. Click Application launcher Application launcher > Administration Administration > Configuration Configuration > Evaluations and select Macros.

  2. Click the category in which you keep the script.

  3. Select the script and click Export Export.

  4. If the script executes imported common files during runtime, you can enable the required files and confirm the inclusion of the files in the export file. Otherwise, only the script is exported.

  5. Navigate to the file location where you want to save the file and click Save.

The script has been saved.

Access privileges Restrict access for execution

By default, all users of a tenant have access to all scripts. You can make scripts available only to members of defined user groups.

  1. Click Application launcher Application launcher > Administration Administration > Configuration Configuration > Evaluations and select Macros.

  2. Click the category in which you keep the script.

  3. Select the script, click Access privileges Restrict access, and enable Restrict access to user groups. All user groups available on this tenant are displayed. Make sure that a related user group was created in ARIS Administration.

  4. Enable the related user groups and click Apply.

The script can be run only by members of the selected user groups.