Dim hasil As Integer
Private Sub Command1_Click()
If (Tambah.Value = False) And (Kurang.Value = False) And (kali.Value = False) And (bagi.Value = False) Then
MsgBox "Pilih Operasi", vbOKOnly, "Warning"
Else
Text1.Text = hasil
End If
End Sub
Private Sub Command2_Click()
If MsgBox("Anda Yakin", vbYesNo, "Exit") = vbYes Then
End
End If
End Sub
Private Sub Kurang_Click()
hasil = Val(Bil1.Text) - Val(Bil2.Text)
End Sub
Private Sub Option1_Click()
hasil = Val(Bil1.Text) / Val(Bil2.Text)
End Sub
Private Sub Option2_Click()
hasil = Val(Bil1.Text) * Val(Bil2.Text)
End Sub
Private Sub Tambah_Click()
hasil = Val(Bil1.Text) + Val(Bil2.Text)
End Sub
0 komentar:
Posting Komentar