unit taschenrechner01;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, StdCtrls;
type
TForm1 =
class(TForm)
einsE: TButton;
zweiE: TButton;
dreiE: TButton;
vierE: TButton;
fuenfE: TButton;
sechsE: TButton;
siebenE: TButton;
achtE: TButton;
neunE: TButton;
kommaE: TButton;
nullE: TButton;
cancelE: TButton;
plusE: TButton;
minusE: TButton;
malE: TButton;
geteiltE: TButton;
rechnenB: TButton;
rechenzeileE: TLabel;
ergebnisE: TLabel;
procedure einsEClick(Sender: TObject);
procedure zweiEClick(Sender: TObject);
procedure dreiEClick(Sender: TObject);
procedure vierEClick(Sender: TObject);
procedure fuenfEClick(Sender: TObject);
procedure sechsEClick(Sender: TObject);
procedure siebenEClick(Sender: TObject);
procedure achtEClick(Sender: TObject);
procedure neunEClick(Sender: TObject);
procedure kommaEClick(Sender: TObject);
procedure nullEClick(Sender: TObject);
procedure cancelEClick(Sender: TObject);
procedure plusEClick(Sender: TObject);
procedure minusEClick(Sender: TObject);
procedure malEClick(Sender: TObject);
procedure geteiltEClick(Sender: TObject);
procedure rechnenBClick(Sender: TObject);
private
{ Private-Deklarationen }
public
{ Public-Deklarationen }
end;
var
Form1: TForm1;
implementation
{$R *.dfm}
procedure TForm1.einsEClick(Sender: TObject);
var eins:char;
begin
rechenzeileE.Caption := rechenzeileE.Caption + '
1';
end;
procedure TForm1.zweiEClick(Sender: TObject);
var zwei:char;
begin
rechenzeileE.Caption := rechenzeileE.Caption + '
2';
end;
procedure TForm1.dreiEClick(Sender: TObject);
var drei:char;
begin
rechenzeileE.Caption := rechenzeileE.Caption + '
3';
end;
procedure TForm1.vierEClick(Sender: TObject);
var vier:char;
begin
rechenzeileE.Caption := rechenzeileE.Caption + '
4';
end;
procedure TForm1.fuenfEClick(Sender: TObject);
var fuenf:char;
begin
rechenzeileE.Caption := rechenzeileE.Caption + '
5';
end;
procedure TForm1.sechsEClick(Sender: TObject);
var sechs:char;
begin
rechenzeileE.Caption := rechenzeileE.Caption + '
6';
end;
procedure TForm1.siebenEClick(Sender: TObject);
var sieben:char;
begin
rechenzeileE.Caption := rechenzeileE.Caption + '
7';
end;
procedure TForm1.achtEClick(Sender: TObject);
var acht:char;
begin
rechenzeileE.Caption := rechenzeileE.Caption + '
8';
end;
procedure TForm1.neunEClick(Sender: TObject);
var neun:char;
begin
rechenzeileE.Caption := rechenzeileE.Caption + '
9';
end;
procedure TForm1.kommaEClick(Sender: TObject);
var punkt:char;
begin
rechenzeileE.Caption := rechenzeileE.Caption + '
.';
end;
procedure TForm1.nullEClick(Sender: TObject);
var null:char;
begin
rechenzeileE.Caption := rechenzeileE.Caption + '
0';
end;
procedure TForm1.cancelEClick(Sender: TObject);
begin
rechenzeileE.Caption :='
';
end;
procedure TForm1.plusEClick(Sender: TObject);
var plus:char;
begin
rechenzeileE.Caption := rechenzeileE.Caption + '
+';
end;
procedure TForm1.minusEClick(Sender: TObject);
var minus:char;
begin
rechenzeileE.Caption := rechenzeileE.Caption + '
-';
end;
procedure TForm1.malEClick(Sender: TObject);
var mal:char;
begin
rechenzeileE.Caption := rechenzeileE.Caption + '
*';
end;
procedure TForm1.geteiltEClick(Sender: TObject);
var geteilt:char;
begin
rechenzeileE.Caption := rechenzeileE.Caption + '
/';
end;
procedure TForm1.rechnenBClick(Sender: TObject);
begin
end;
end.