Macros

Macros can be used in workflow functionality such as workflow e-mails, REST calls, or scripts to reference Therefore™ index data or process- or system information, and add it at runtime.

Not every Macro dialog contains all options. For example, only index data fields can be selected when configuring a REST URL.

To open the Macros dialog, click the Macros button while configuring emails, REST calls, or scripts.

Workflow macros

In this pane, workflow macros to add system information are listed.

Macro Description
[@AdditionalInfo]

Contents of the workflow information text box.

[@AssignedToUserDispName]

The display name of the user to whom the current instance is assigned.

[@AssignedToUserName]

Username of the user to whom the current instance is assigned.

[@CaseDefNo] Adds the case definition number.
[@CaseNo] Adds the case number.
[@CategoryNo] Adds the category number.
[@CurrentDate]

Adds the current date.

[@CurrentDateTime] 

Adds the current date and time.

[@EformLink]

Inserts a link to an existing eForm.

[@SignatureDocID] Adds the ID of an eSignature document.
[@InitiatorDispName]

The display name for the initiator of the current instance.

[@InitiatorDomain] The domain of the initiator of the current instance.
[@InitiatorEmail]

E-mail of the initiator of the current instance.

[@InitiatorName]

Username of the initiator of the current instance.

[@InstanceNo]

Unique number for the instance.

[@MainDocNo]

Unique Therefore™ document number for the main document.

[@PrevTaskUserDispName]

The display name for user that processed the previous manual task.

[@PrevTaskUserDomain]

The domain of the user that processed the previous manual task.

[@PrevTaskUserEmail]

The e-mail address of the user that processed the previous manual task.

[@PrevTaskUserName]

Username of the user that processed the previous manual task.

[@ProcessDueDate]

The date on which the workflow process is due. This date is calculated by adding the specified process duration to the workflow process start date.

[@ProcessDueDateTime]

The date and time on which the workflow process is due. This date is calculated by adding the specified process duration to the workflow process start date and time.

[@ProcessName]

The name of the workflow process.

[@ProcessStartDate]

The date on which the workflow process was started.

[@ProcessStartDateTime]

The date and time on which the workflow process was started.

[@Server]

The DNS name of the Therefore™ Server which started the current instance.

[@TaskDueDate]

The date on which a specific task is due. (Task start-date plus the specified task duration).

[@TaskDueDateTime]

Date & time when a specific task is due. This date is calculated by adding the specified task duration to the task start date and time.

[@TaskNameFrom]

The name of the previous task.

[@TaskNameTo]

The name of the next task that will be transitioned to.

[@TaskStartDate]

The date on which a specific task started.

[@TaskStartDateTime]

The date and time on which a specific task started.

[@TenantName] In a multi-tenant Therefore™ system , using this macro adds the tenant name.
[@TokenNo] Returns the workflow token number. This macro can be used if an access token to the workflow instance and document was created in a Call REST task for callback from the external function.
[@UserDisplayName]

The display name for the user who performed the last action.

[@UserDomain]

The domain name of the current user.

[@UserEmail]

The e-mail of the current user.

[@UserName]

The username of the user who performed the last action.

[@WebClientDocLink]

A URL to open the main document in the Therefore™ Web Client.

[@WebClientLink]

A URL to open the workflow instance in Therefore™ Web Client.

[@WebPortalDocLink]

A URL to open the workflow instance in Therefore™ Portal.

Info Icon

For internal Therefore™ users, the macros with display name will return the username.

Index data fields

In this pane, index data fields that are configured for the category are listed. The fields can also be added manually in the email editor, code, or URL by referencing [Field ID].

Checkboxes

Insert HTML Button
Check this box to insert a selected Workflow or Index data field macro as a clickable button into the email. The button is pre-formatted. Switch the editor to Code View (<>) to edit the button's link, text, and formatting.

Allow HTML
Check this box to insert a |HTML marker into a selected macro.

In general, macros should only be used to add text to an email not HTML coding. But if there are very specific reasons this option can be used to copy HTML from index data to the email.