FindFirst/FindNext (from http://www.delphibasics.co.uk/RTL.asp?Name=FindNext)[pascal] var
searchResult : TSearchRec;

begin
// Try to find regular files matching Unit1.d* in the current dir
if FindFirst('Unit1.d*', faAnyFile, searchResult) = 0 then
begin
repeat
ShowMessage('File name = '+searchResult.Name);
ShowMessage('File size = '+IntToStr(searchResult.Size));
until FindNext(searchResult) <> 0;

// Must free up resources used by these successful finds
FindClose(searchResult);
end;
end;[/pascal]