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

FindFirstUTF8

Starts searching for files matching the specified path value

Declaration

Source position: lazfileutils.pas line 110

function FindFirstUTF8(

  const Path: string;

  Attr: LongInt;

  out Rslt: TSearchRec

):LongInt;

Arguments

Path

  

Path and/or file name to locate

Attr

  

File attributes to include in the search

Rslt

  

Search record for the first matching file

Function result

Last error number encountered in the function

Description

FindFirstUTF8 searches the file specified in Path. Normal files, as well as all special files which have the attributes specified in Attr will be returned.

It returns a SearchRec record for further searching in Rslt. Path can contain wildcard characters; ? (matches any single character) and * (matches 0 or more arbitrary characters). In this case FindFirstUTF8 will return the first file which matches the specified criteria.

The return value contains the result from GetLastError; a non-zero value indicates that no files matching the criteria were found.

See also

#rtl.Dos.FIndFirst

The latest version of this document can be found at lazarus-ccr.sourceforge.net.