Salesforce

Event Logic Unit Scope (Magic xpa 3.x)

« Go Back

Information

 
Created ByKnowledge Migration User
Approval Process StatusPublished
Objective
Description

Event Logic Unit Scope (Magic xpa 3.x)

Often an Event type logic unit can be defined in an ancestor task. However, as far as the runtime task tree is concerned, the logic executed in such a high-level unit is regarded as though it runs in the task that triggered the event. This means that even though the logic may be executed by an ancestor task, the entire runtime tree variables, the opened I/O devices in the runtime tree, and accessibility to the runtime tree tasks are available to the logic unit. This figure illustrates cascading program calls using simple call operations and event triggering.

In the example shown above, Program A calls Program B, which in turn calls program C. Program C raises an event that is handled by a logic unit defined in Program A. This logic unit handler then calls Program D.

The runtime tree visible to Program D is the same as if Program D had been called directly from Program C.

Variables

All the runtime tree variables are available to Program D, starting with the first Program A variable and ending with the last variable of Program D.

Task Tree

The generation of each task is as follows: Program D = 0, Program C = 1, Program B = 2, and Program A = 3.

I/O Devices

Program D can output or input forms to an I/O device opened in any other program in the runtime tree using the I/O name to use property of its I/O entry.

Note:

When you refer to the runtime tree variables and tasks directly from the logic unit, and not from a task called from the logic unit, the generation and variable stack is the same as if the unit’s operations were executed from program C. For example, the generations available to the unit are: Program C = 0, Program B = 1, Program A = 2.

Parallel Programs and Modeless Browser Tasks

Calling a parallel program or a browser program set to be modeless, creates a new additional runtime task branch that starts at the top program and continues through the program from which the call operation was executed down to the called program.

Reference
Attachment 
Attachment