Tugas 2.2 Membuat Perhitungan Harga Setelah Diskon 10% ( Klik Tombol Hitung dan Fungsi KeyAscii)

Gambar Aplikasi Saat Runtime


Berikut adalah source code aplikasi tersebut :

Private Sub Hitung_Click()
    Txtdiskon = Val(Txthrgawal) * 0.1
    Txttotal = Val(Txthrgawal) - Val(Txtdiskon)
End Sub

---------------------------------------------------------------------------------
Private Sub Quit_Click()
    End
End Sub
--------------------------------------------------------------------------------- 
Private Sub Txthrgawal_KeyPress(KeyAscii As Integer)
    If KeyAscii = 13 Then
    Txtdiskon = Val(Txthrgawal) * 0.1
    Txttotal = Val(Txthrgawal) - Val(Txtdiskon)
    End If
End Sub
---------------------------------------------------------------------------------
Private Sub Ulang_Click()
    Txthrgawal = ""
    Txtdiskon = ""
    Txttotal = ""
End Sub

Related Posts:

0 Response to "Tugas 2.2 Membuat Perhitungan Harga Setelah Diskon 10% ( Klik Tombol Hitung dan Fungsi KeyAscii)"

Posting Komentar