2017年9月7日 星期四

FTP & ProgressBar

begin
  ProgressBar.Max := idFTP.Size('xxxxx');
end;


procedure IdFTP_OnWork(ASender: TObject; AWorkMode: TWorkMode; AWorkCount: Int64);
begin
  ProgressBar.Position := AWorkCount;
end;

procedure IdFTP_OnWorkBegin(ASender: TObject; AWorkMode: TWorkMode; AWorkCountMax: Int64);
begin
  ProgressBar.Position := 0;
end;

procedure IdFTP_OnWorkEnd(ASender: TObject; AWorkMode: TWorkMode);
begin
  ProgressBar.Position := 0;
end;

沒有留言:

張貼留言