Sign in Join
FPDoc Onlineexperiment

GetLastOSError function

In unit sysutils

Return the last code from the OS.

Declaration

pascal
function GetLastOSError: Integer

Description

GetLastOSError returns the error code from the last operating system call. It does not reset this code. In general, it should be called when an operating system call reported an error condition. In that case, GetLastOSError gives extended information about the error.

No assumptions should be made about the resetting of the error code by subsequent OS calls. This may be platform dependent.

See also

An experiment, built from development snapshots. Not the official Free Pascal or Lazarus documentation.