Use: Label, Textbox, Option, Frame and command buttons.
Terms of Problem:
When the selected item code item name and price will appear.
When the inputted number of buy and clicked enter then the total price will appear.
When the money to pay the money back even typed will appear.
This is the listing :
Private Sub ckobar_Click()
If ckobar.Text = "EMB" Then
txtnabar.Text = "EMBER"
txtharga.Text = 15000
ElseIf ckobar.Text = "PNC" Then
txtnabar.Text = "PANCI"
txtharga.Text = 75000
Else
txtnabar.Text = "SAPU"
txtharga.Text = 10000
End If
End Sub
Private Sub cmdinput_Click()
txtnapem.Text = ""
ckobar.Text = "-PiliH-"
txtnabar.Text = ""
txtharga.Text = ""
txtfasilitas.Text = ""
optdelivery = Clear
optditempat = Clear
txtjumbel.Text = ""
txttotbay.Text = ""
txttotbay.Enabled = False
txtubay.Text = ""
txtukem.Text = ""
txtukem.Enabled = False
txtnapem.SetFocus
End Sub
Private Sub cmdkeluar_Click()
If MsgBox("Yakin lo mau Keluar ?? Serius ??", 36, "Peringatan") = vbYes Then
End
End If
End Sub
Private Sub Form_Load()
ckobar.AddItem ("EMB")
ckobar.AddItem ("PNC")
ckobar.AddItem ("SPU")
'cmdinput.SetFocus
End Sub
Private Sub optdelivery_Click()
txtfasilitas.Text = 15000
txtjumbel.SetFocus
End Sub
Private Sub optditempat_Click()
txtfasilitas.Text = 0
txtjumbel.SetFocus
End Sub
Private Sub txtjumbel_KeyPress(KeyAscii As Integer)
If KeyAscii = 13 Then
txttotbay.Text = Val(txtharga) * Val(txtjumbel) + Val(txtfasilitas)
txtubay.SetFocus
End If
End Sub
Private Sub txtubay_Change()
txtukem.Text = Val(txtubay) - Val(txttotbay)
End Sub
Enjoy it..^_^
if any one does not understand please ask and leave a comment ..^_^
ReadMore...