Previous Topic: RDJFCB()

Next Topic: SAM()

REDIRECT()

Use REDIRECT() to send TRACE or SAY output to a stack instead of to the ISERVE log. The recorded information may be retrieved later using standard stack-manipulating functions and commands.

Syntax

The REDIRECT() function has this syntax:

stack = REDIRECT({TRACE|SAY},[stack])

Arguments

The REDIRECT() function takes these arguments:

TRACE

Redirect TRACE output.

SAY

Redirect SAY output.

stack

Stack number to receive the redirected output. To terminate redirection of the TRACE or SAY output, code this argument as OFF.

Default: The current value is returned but not changed.

Return Codes

The REDIRECT() function produces these return codes:

101 - 102

ARG n MISSING OR INVALID

Example

x = redirect('trace',5)      /* Trace output is written on
                                 stack 5 */
 x = redirect('say','off')    /* Redirection of SAY output is
                                 terminated.*/