Microsoft® Windows® Script Host
Quit Method
WSH Reference
Version 1

Applies To


Description
Quits execution with a specified error code.
Syntax
object.Quit [intErrorCode]
Parameters
Part Description
object WScript object.
intErrorCode Optional. If this parameter is included, WScript returns it as the process exit code. If intErrorCode is omitted, WScript returns zero (0) as the process exit code.
Example
The following example quits execution and returns an error code of 1:
WScript.Quit 1