Sign in Join
FPDoc Onlineexperiment

FExpand function

In unit Dos

Expand a relative path to an absolute path.

Declaration

pascal
function FExpand(const path: PathStr): PathStr

Description

FExpand takes its argument and expands it to a complete filename, i.e. a filename starting from the root directory of the current drive, prepended with the drive-letter or volume name (when supported).

On case sensitive file systems (such as Unix and Linux), the resulting name is left as it is, otherwise it is converted to uppercase.

Errors

FSplit

Example: ex11

pascal
Program Example11;
uses Dos;

{ Program to demonstrate the FExpand function. }

begin
  WriteLn('Expanded Name of this program is ',FExpand(ParamStr(0)));
end.

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