diskon

Private Sub cmdhitung_Click()
Dim a, b, c As Double
a = Val(txtawal.Text)
b = (a * 0.1)
c = (a – b)
txtdiskon.Text = b
txtakhir.Text = c
End Sub

Private Sub cmdkeluar_Click()
Unload Me
End Sub

Private Sub cmdulangi_Click()
txtawal.SetFocus
txtawal = “”
txtdiskon = “”
txtakhir = “”
End Sub

Private Sub txtawal_KeyPress(KeyAscii As Integer)
If KeyAscii = 13 Then
txtdiskon.SetFocus
End If
End Sub

Private Sub txtdiskon_KeyPress(KeyAscii As Integer)
If KeyAscii = 13 Then
txtakhir.SetFocus
End If
End Sub

Tinggalkan komentar