Exists(FileName: String): Boolean;
FileName — a path and name of the file, existence of which should be checked.
The Exists method indicates whether the file exists.
Sub Main;
Var
s: String;
Begin
If File.Exists("c:\New_folder\1.txt") Then
s:="Yes";
Else
s:="No";
End If;
End Sub Main;
After executing this example,, variable "s" contains Yes if file 1.txt exists.
See also: