Advertisement
rikokurniawan

Waktu

Dec 29th, 2012
1,139
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Delphi 0.71 KB | None | 0 0
  1. procedure TFKJW.Button4Click(Sender: TObject);
  2. Var a,b: Real;
  3. begin
  4.   a:=StrToFloat(Edit1.Text);
  5.   b:=StrToFloat(EKecepatan.Text);
  6.   If (Combobox4.ItemIndex=0) And
  7.     (ComboBox3.ItemIndex=0) then
  8.     Begin
  9.       Label9.Caption:=FloatToStr(a/b) + ' Jam' ;
  10.     End
  11.   Else If (Combobox4.ItemIndex=0) And
  12.     (ComboBox3.ItemIndex=1) then
  13.     Begin
  14.       Label9.Caption:=FloatToStr(a/(b/100)) + ' Jam' ;
  15.     End
  16.   Else If (Combobox4.ItemIndex=1) And
  17.     (ComboBox3.ItemIndex=0) then
  18.     Begin
  19.       Label9.Caption:=FloatToStr((a/100)/b) + ' Jam' ;
  20.     End
  21.   Else If (Combobox4.ItemIndex=1) And
  22.     (ComboBox3.ItemIndex=1) then
  23.     Begin
  24.       Label9.Caption:=FloatToStr((a/100)/(b/100)) + ' Jam' ;
  25.     End;
  26. end;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement