Monday

Presence Detect File



To check whether a file exists in a particular directory, you can use that function is served Delphi.The formula functions:
FileExists(const FileName:string):boolean.

The first step: put the Edit Button and in FormStep two: fill the program with the program listings below

Procedure Tfrom.Button1Click(Sender:TObject);
begin
if Edit1.Text = ' ' then
ShowMessage('isikankan nama file yang dicari')
else
begin
if FileExits(Edit1.Text) = true then // jika ada
ShowMessage('file " ' +Edit1.Text + ' " ada. ')
else // Jika tidak ada
showMessage('File " ' +Edit1.Text + ' " tidak dtemukan. ');
end;
end;  

Third step: Click on the Run. 

No comments:

Post a Comment

Related Posts with Thumbnails