This is default featured slide 1 title

Go to Blogger edit html and find these sentences.Now replace these sentences with your own descriptions.

This is default featured slide 2 title

Go to Blogger edit html and find these sentences.Now replace these sentences with your own descriptions.

This is default featured slide 3 title

Go to Blogger edit html and find these sentences.Now replace these sentences with your own descriptions.

This is default featured slide 4 title

Go to Blogger edit html and find these sentences.Now replace these sentences with your own descriptions.

This is default featured slide 5 title

Go to Blogger edit html and find these sentences.Now replace these sentences with your own descriptions.

Pages

Kamis, 10 Oktober 2013

Delphi 7 ( Perhitungan Nilai, Input Biodata dan Perhitungan Casir dengan Pindah form )

UNIT 1
implementation
uses
unit2,unit3,unit4;

{$R *.dfm}

procedure TForm1.Button1Click(Sender: TObject);
begin
Form2.Show;
end;

procedure TForm1.Button2Click(Sender: TObject);
begin
Form3.Show;
end;

procedure TForm1.Button3Click(Sender: TObject);
begin
Form4.Show;
end;

end.

UNIT 2
implementation
uses
unit1;
{$R *.dfm}

procedure TForm2.Button1Click(Sender: TObject);
var nilai_tugas,nilai_uts,nilai_uas,tugas,uts,uas,total:real;
var keterangan:string;
begin
tugas:=StrToFloat(Edit3.Text);
uts:=StrToFloat(Edit4.Text);
uas:=StrToFloat(Edit5.Text);
nilai_tugas:=(tugas*30)/100;
nilai_uts:=(uts*35)/100;
nilai_uas:=(uas*35)/100;
total:=(nilai_tugas+nilai_uts+nilai_uas);
Edit6.Text := FloatToStr(total);
if total >= 65 then
Edit7.Text := 'lulus'
else
Edit7.Text := 'tidak lulus';


end;


end.

UNIT 3
implementation
uses
unit1;
{$R *.dfm}

procedure TForm3.Button1Click(Sender: TObject);
var nama,tempat,kelamin,status,nama_anda,tempat_anda,kelamin_anda,status_anda:string;
var nim,umur,nim_anda,umur_anda:integer;
begin
nama:=string(Edit1.Text);
nim:=StrToInt(Edit2.Text);
umur:=StrToInt(Edit3.Text);
tempat:=String(Edit4.Text);
kelamin:=string(Edit5.Text);
status:=string(Edit6.Text);

Label3.Caption:=Edit1.Text;
Label4.Caption:=Edit2.Text;
Label9.Caption:=Edit3.Text;
Label10.Caption:=Edit4.Text;
Label11.Caption:=Edit5.Text;
Label12.Caption:=Edit6.Text;
end;


end.

UNIT 4
implementation
uses
unit1;
{$R *.dfm}

procedure TForm4.Button1Click(Sender: TObject);
var harga,diskon,total:real;
begin
harga:=StrToFloat(Edit2.Text);
diskon:=(harga*10)/100;
total:=harga-diskon;
Edit4.Text:=FloatToStr(diskon);
Edit5.Text:=FloatToStr(total);




end;

procedure TForm4.Button2Click(Sender: TObject);
var uang,kembali,total:real;
begin
uang:=StrToFloat(Edit6.Text);
total:=StrToFloat(Edit5.Text);
kembali:=uang-total;
Edit7.Text:=FloatToStr(kembali);
end;

procedure TForm4.Button3Click(Sender: TObject);
begin
close;
end;


end.