Unduh FTP: http://www.7880.com/info/article-19938be0.html
http://community.csdn.net/expert/topic/3300/3300012.xml?temp=5.028933e-02
Unduh FTP: Kontrol TIDFTP (Delphi7 Indy)
Unduh http: (delphi7) Gunakan kontrol indy desain untuk mengunduh file jaringan //////////////////
Tambahkan kontrol di Form1:
Dua Kontrol Indy: IdantiFreeze1, IDHTTP1;
Tombol: Button1;
Bilah Kemajuan: ProgressBar1 menampilkan kecepatan unduhan
Prosedur TFORM1.BUTTON1CLICK (Pengirim: Tobject);
var
Mystream: tMemoryStream;
Mulai
IDANTIFREEZE1.Only Whenidle: = false; // diatur untuk membuat program bereaksi.
MyStream: = tMemoryStream.create;
mencoba
Idhttp1.get ('http://www.appcontrols.com/demos/exe/httpdemo.exe',mystream);
kecuali
Showmessage ('No Download Success!');
Mystream.free;
KELUAR;
akhir;
MyStream.savetofile (extractFilePath (paramstr (0))+'httpdemo.zip');
Mystream.free;
Showmessage ('OK');
akhir;
Prosedur TFORM1.IDHTTP1WORKBEGIN (Pengirim: TOBJEK; AWORKMODE: TWORKMODE;
const aworkcountmax: integer);
Mulai
// Sebelum memulai unduhan, atur nilai maksimum ProgressBar1 ke ukuran data yang perlu diterima.
ProgressBar1.max: = AworkCountmax;
ProgressBar1.min: = 0;
ProgressBar1.Posisi: = 0;
akhir;
Prosedur TFORM1.IDHTTP1WORK (Pengirim: Tobject; AworkMode: TworkMode;
const aworkcount: integer);
Mulai
// Saat menerima data, kemajuan akan ditampilkan di ProgressBar1.
ProgressBar1.position: = progressBar1.position+AworkCount;
akhir;