XCALL

Call an external subroutine or function

WSupported on Windows
USupported on Unix
VSupported on OpenVMS
NSupported in Synergy .NET
XCALL subroutine([argument, ...])

subroutine

The name of an external subroutine or function to which control will be transferred.

argument

(optional) A list of one or more arguments that are passed to the subroutine or function.
(a or n)

The XCALL statement transfers control to an external subroutine or user-defined function. (It cannot be used to call system-supplied functions.) Upon return from the subroutine or function, control is transferred to the statement following the XCALL statement.

Note

Any ONERROR traps set in the calling program are disabled while the external subroutine is being processed. Once control returns to the calling program, the error traps are re-enabled.

Writing and calling subroutines and functions

See USING-ENDUSING for an example that uses the XCALL statement.