Program Harga Photo Copy
Listing Programnya :
Public Class Form2
Private Sub Form2_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
Dim x As Integer
For x = 20 To 500 Step 10
JL.Items.Add(x)
Next
End Sub
Private Sub Btnproses_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Btnproses.Click
TH.Text = HPL.Text * JL.Text
Pembayaran.Text = TH.Text - Discount.Text
End Sub
Private Sub JL_SelectedIndexChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles JL.SelectedIndexChanged
If JL.Text <= 200 Then
HPL.Text = "90"
ElseIf JL.Text >= 200 Then
HPL.Text = "100"
End If
End Sub
Private Sub TH_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles TH.TextChanged
If TH.Text >= 500000 Then
Discount.Text = TH.Text * 0.15
Else
Discount.Text = 0
End If
End Sub
Private Sub Btnhapus_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Btnhapus.Click
End Sub
Private Sub Btnkeluar_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Btnkeluar.Click
Me.Close()
End Sub
End Class
Hasilnya :
Tidak ada komentar:
Posting Komentar