You are here: Reference > Activity methods > Calling another activity

Calling another activity

Use the Call instruction to cause the current activity to find another specified activity and execute it. When that activity completes, control returns to the calling activity.

The calling activity can pass parameter values to the called activity in two ways.

See Call instruction parameters for information about the parameters this call can take.

You can also pass a reference to a clipboard page as a parameter. The called activity can then use this Page Name parameter as if it were the clipboard page. See Passing Page Name parameters.

Notes on Out parameters

The Call instruction in an activity examines the In/Out value of each parameter in the called activity:

In a chain of calling activities (activity Alpha calls Beta which calls Gamma), a property passed by reference from Alpha to Beta can also be passed by reference to Gamma, and changes to the Out parameter made within Gamma can be passed all the way back to Alpha. This corresponds to the behavior of call-by-reference in many programming languages.

Results

The system uses rule resolution to locate the activity. It then constructs or shares a parameter page and transfers control to the activity.

Accessing iteration values in a called activity

If an activity step involving iteration contains a Call instruction, special parameters are added to the parameter page and can be used within the called activity to access iteration details. See Activity Form — Completing the Steps tab — Entering loops.

Asynchronous execution

As an alternative to the Call instruction, you can use the Queue instruction to execute an activity asynchronously in parallel, in a child requestor.