How do I download Delphi through FTP servers with authentication?

4

I have some files on an FTP server on Hostinger, and these files have been left there since links from FTP servers never change. As they are very important to make updates to my application, Delphi should download them.

    
asked by anonymous 23.08.2015 / 21:08

1 answer

1

You can do with the TIdFTP component. Ex.:

IdFTP1.Disconnect();

IdFTP1.Host := 'ftp.seuftp.com';
IdFTP1.Port := 21;
IdFTP1.Username := 'usuario';
IdFTP1.Password := 'senha';
IdFTP1.Passive := true;

IdFTP1.Connect(true, 10000);    

IdFTP1.Get (arquivoNoServidor, arquivoDestino, true, false);

Font

    
23.08.2015 / 21:39