Program Mengitung volume dan luas selimut kerucut via Delphi 2010
ini program buat adik adik yang ingin mengel delphi 2010.
semoga berkenan dan bermanfaat
1.ni dia output programnya
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, StdCtrls, pngimage, ExtCtrls;
TForm1 = class(TForm)
GroupBox1: TGroupBox;
Button1: TButton;
Button2: TButton;
Button3: TButton;
GroupBox2: TGroupBox;
Edit1: TEdit;
Edit2: TEdit;
Edit3: TEdit;
Label1: TLabel;
Label2: TLabel;
Label3: TLabel;
GroupBox3: TGroupBox;
Label4: TLabel;
Label5: TLabel;
Edit4: TEdit;
Edit5: TEdit;
Image1: TImage;
Label6: TLabel;
Label7: TLabel;
procedure Button1Click(Sender: TObject);
procedure Button2Click(Sender: TObject);
procedure Button3Click(Sender: TObject);
private
{ Private declarations }
public
{ Public declarations }
end;
var
Form1: TForm1;
implementation
{$R *.dfm}
procedure TForm1.Button1Click(Sender: TObject);
var tinggi,jari,simir,volume,lusel : real ;
begin
tinggi := StrToFloat(Edit1.Text ) ;
jari := StrToFloat(Edit2.Text ) ;
simir := strtofloat (Edit3.text) ;
volume :=(1/3)*3.14*jari*jari*tinggi ;
lusel := (3.14 * jari *(jari + simir ));
edit4.Text := floattostr (volume ) ;
edit5.Text := floattostr (lusel);
end;
procedure TForm1.Button2Click(Sender: TObject);
begin
edit1.Text := '';
edit2.Text := '';
edit3.Text := '';
edit4.Text := '';
edit5.Text := '';
end;
procedure TForm1.Button3Click(Sender: TObject);
begin
Close
end;
end.
0 Response to "Program Mengitung volume dan luas selimut kerucut via Delphi 2010"
Post a Comment