System.GetLastError

From Appmethod Libraries
Jump to: navigation, search

Object Pascal

function GetLastError: Integer; stdcall;

Properties

Type Visibility Source Unit Parent
function external public WindowsAPIs.INC System System

Description

Returns the last error reported by an operating system API call.

GetLastError returns the last error reported by an API call into the operating system. Calling this function usually resets the operating system error state. The GetLastError function returns an error code from the operating system. After that, when calling SysErrorMessage on that error code, GetLastError will return a string with a formatted error message associated with the error code.

See Also

Code Examples