Woher stammen denn die Datei-Informationen? Vom
FTP Server? Versuch mal folgendes:
Delphi-Quellcode:
var
SaveFilename:
string;
begin
SaveFilename := extractfilepath(Application.Exename) + ExtractFileName(Listbox1.Items.GetText);
if FileExists(SaveFilename)
then
DeleteFile(SaveFilename);
FTP.Get(Listbox1.Items.GetText, SaveFilename);
end;