SetConsoleExitCode (open)

Set an errorcode to return from console scripts

Syntax

LOADLIB "wh::os.whlib";

MACRO SetConsoleExitCode(INTEGER errorcode)

Parameters

INTEGER errorcode

Errorcode to return (0-255, but remember that 1 is also used for failed scripts)

Description

Set the errorcode, or exitcode, to return to the operating system. Generally, 0 is used to indicate that no errors occured, and 1 and higher are used for error codes. If this function is not called, 0 is returned to the OS