procedure TForm1.Button1Click(Sender: TObject);
var
a:integer;
begin
a:=StrToInt(Edit2.Text);
if (a>=81) and (a<=100) then
Label11.Caption:= ('A')
else
if(a>=61) and (a<=80)then
Label11.Caption:= ('B')
else
if(a>=41) and (a<=60) then
Label11.Caption:=('C')
else
if(a>=16) and (a<=40) then
Label11.Caption:=('D')
else
Label11.Caption:=('E');
Label8.Caption:=Edit1.Text;
Label9.Caption:=ComboBox1.Text;
Case RadioGroup1.ItemIndex of
0 : begin
Label10.Caption:=('Laki-Laki');
end;
1 : begin
Label10.Caption:=('Perempuan');
end;
end;
end;
procedure TForm1.Button2Click(Sender: TObject);
begin
Edit1.Clear;
Edit2.Clear;
Label8.Caption:= ' ';
Label9.Caption:= ' ';
Label10.Caption:= ' ';
Label11.Caption:= ' ';
end;
procedure TForm1.Button3Click(Sender: TObject);
begin
Close;
end;
end.
Tidak ada komentar:
Posting Komentar
Monggo dikoment.. :)