Delphi-PRAXiS

Delphi-PRAXiS (https://www.delphipraxis.net/forum.php)
-   Sonstige Fragen zu Delphi (https://www.delphipraxis.net/19-sonstige-fragen-zu-delphi/)
-   -   Delphi Fortschritt in Gauge anzeigen (https://www.delphipraxis.net/7574-fortschritt-gauge-anzeigen.html)

quakergod 15. Aug 2003 20:16


Fortschritt in Gauge anzeigen
 
hi!

hab mittels IEDownload Komponente ein Download Programm 'gemacht' ^^

Delphi-Quellcode:
procedure TForm1.IEDownload1Progress(Sender: TBSCB; ulProgress,
  ulProgressMax, ulStatusCode: Cardinal; szStatusText: PWideChar;
  ElapsedTime, Speed, EstimatedTime: string);
var
  s: string;
begin
  s := BindstatusText(ulStatusCode);
  if ulStatusCode = BINDSTATUS_DOWNLOADINGDATA then
    s := S ;

  Label1.Caption := 'Verbleibend: '+ EstimatedTime;
  Label2.Caption := 'Geladen: '+ InttoStr(ulProgress) + ' / ' + InttoStr(ulProgressMax) + '';
  Label3.Caption := 'Geschwindigkeit: '+ Speed;
  Label4.Caption := 'Abgelaufen: '+ ElapsedTime;
  Label6.Caption := 'Status: '+ BindstatusText(ulStatusCode);
end;
was jetzt noch fehlt wäre eine Fortschrittsanzeuige (Gauge) !
Ich weiss nicht genau wie ich das mit den Werten ulProgress und ulProgressMax machen soll.. :oops:


EDIT: Habs hingekriegt !!! :firejump: :hello:
Delphi-Quellcode:
Form1.Gauge1.Progress := MulDiv(ulProgress,100,ulProgressMax);


Alle Zeitangaben in WEZ +1. Es ist jetzt 08:36 Uhr.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO © 2011, Crawlability, Inc.
Delphi-PRAXiS (c) 2002 - 2023 by Daniel R. Wolf, 2024-2025 by Thomas Breitkreuz