Sign in Join
FPDoc Onlineexperiment

GetUserDir function

In unit sysutils

Returns the current user's home directory.

Declaration

pascal
function GetUserDir: string

Description

GetUserDir returns the home directory of the current user. On Unix-like systems (that includes Mac OS X), this is the value of the HOME environment variable. On Windows, this is the PROFILE special folder. On all other platforms, the application installation directory is returned.

If non-empty, it contains a trailing path delimiter.

See also

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