[Overview][Constants][Types][Procedures and functions][Variables][Index] Reference for unit 'LazFileUtils' (#lazutils)

CreateAbsoluteSearchPath

Concatenates BaseDirectory and SearchPath to form an absolute path to search for files.

Declaration

Source position: lazfileutils.pas line 102

function CreateAbsoluteSearchPath(

  const SearchPath: string;

  const BaseDirectory: string

):string;

Arguments

SearchPath

  

The search path (a relative path).

BaseDirectory

  

The base directory from which to form the absolute path.

Function result

The absolute path formed by concatenating BaseDirectory and SearchPath.

Description

CreateAbsoluteSearchPath concatenates BaseDirectory and SearchPath to form an absolute path to search for files.

The routine adds the appropriate path delimiters to the BaseDirectory string, and adds the search path. Each directory in the search path is examined to ensure that each is also an absolute directory path. The return value contains the fully-formed absolute search path.

If BaseDirectory is empty, the function exits with a return value equal to SearchPath. if SearchPath is empty, the function exits with empty string ('') in the return value.


Version 3.2 Generated 2024-02-25 Home