The EGL transfer statement gives control from one main program to another, ends the transferring program, and optionally passes a record whose data is accepted into the receiving program's input record. You cannot use a transfer statement in a called program.
EGL implements the statement with the CICS XCTL command and uses the COMMAREA option of that command to pass the record, after which the record data starts in the first byte of the CICS common area.
If the initial program in a transaction is a main batch program, transfer to a main transaction program is not supported. If the initial program is a main transaction, transfer is not valid to a main batch program that accesses the I/O PCB.
The linkage options part, transferLink element has no effect when you are transferring control from Java code to Java code, but is meaningful otherwise.
If you are running in VisualAge Generator compatibility mode, you can specify the option externallyDefined in the transfer statement, as occurs for programs migrated from VisualAge Generator; but it is recommended that you set the equivalent value in the linkage options part instead. For details on VisualAge Generator compatibility mode, see Compatibility with VisualAge Generator.
Related concepts
Compatibility with VisualAge Generator
Name aliasing
Related reference
transferName