sysError

returns the operating system's error status.

# Metadata

Platforms: desktop, server OS: mac, windows, linux Introduced: 1.0 Security:

# Syntax

the sysError

# Examples

the sysError

if the sysError is zero then answer "Success!"

# Description

Use the sysError function to obtain the reason a command that makes an operating-system request failed.

On Unix systems, the sysError function returns the value of the "errno" variable.

On Windows systems, the sysError function returns the value returned by the "GetLastError()" function.

# Tags

# See

- **keyword:** integer - **command:** close file, kill - **function:** result, sysError, value - **control structure:** function - **glossary:** error message, command, return, variable