unit Unit1;
interface
uses
Windows, Messages, SysUtils, Classes, Graphics, Controls, Forms, Dialogs,
StdCtrls, Menus;
type
TForm1 = class(TForm)
Edit1: TEdit;
Edit2: TEdit;
Label1: TLabel;
Label2: TLabel;
Label3: TLabel;
Edit3: TEdit;
Label4: TLabel;
Label5: TLabel;
Edit4: TEdit;
Edit5: TEdit;
Label6: TLabel;
Label7: TLabel;
Label8: TLabel;
Label9: TLabel;
MainMenu1: TMainMenu;
Datei1: TMenuItem;
Beenden1: TMenuItem;
Berechnen1: TMenuItem;
Zwischenzeit1: TMenuItem;
Hilfe1: TMenuItem;
Info1: TMenuItem;
procedure Beenden1Click(Sender: TObject);
procedure Zwischenzeit1Click(Sender: TObject);
private
{ Private-Deklarationen }
public
{ Public-Deklarationen }
end;
var
Form1: TForm1;
gesamt: real;
teiler,endzeitM, endzeitS, Strecke, Zeit, restmin, restsec: integer;
implementation
{$R *.DFM}
procedure TForm1.Beenden1Click(Sender: TObject);
begin
close;
end;
procedure TForm1.Zwischenzeit1Click(Sender: TObject);
begin
endzeitm:=StrToInt(Edit1.Text);
endzeits:=StrToInt(Edit2.Text);
Strecke:=StrToInt(Edit3.Text);
Zeit:=(endzeitm*60)+endzeits;
Gesamt:=(Zeit/10000)*Strecke;
restmin:=FloatToStr(Gesamt div 60);
restsec:=FloatToStr(Gesamt mod 60);
end;
end.