Silahkan Melihat Tutorial di website kami dengan nyaman ENJOY YOUR LIFE ☕

VB.net :: Program Sederhana VB.NET Penjualan Tiket Film


Assalamualaikum,,,

Dimalam yang dingin ini, sebelum saya main futsal saya sempatkan untuk memposting Program Sederhana VB.NET Penjualan Tiket Film, yang mungkin bisa menjadi referensi anda untuk belajar pemrograman VB.NET.

Langsung saja ya ini Program Sederhana VB.NET Penjualan Tiket Film.

Desain form berikut :




Jika sudah selesai membuat form, berikut listing Proram Sederhana VB.NET Pejualan Tiket Film :

Public Class Form1

    Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
        Kode.Items.Add("A001")
        Kode.Items.Add("A002")
        Kode.Items.Add("A003")
        Kode.Items.Add("A004")
    End Sub

    Private Sub Kode_SelectedIndexChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Kode.SelectedIndexChanged
        If Kode.Text = "A001" Then
            Nama_studio.Text = "Studio 1"
            Kelas.Text = "Eksklusif"
            Harga.Text = 900000
        ElseIf Kode.Text = "A002" Then
            Nama_studio.Text = "Studio 2"
            Kelas.Text = "Bisnis"
            Harga.Text = 800000
        ElseIf Kode.Text = "A003" Then
            Nama_studio.Text = "Studio 3"
            Kelas.Text = "Ekonomi"
            Harga.Text = 700000
        Else
            Nama_studio.Text = "Studio 4"
            Kelas.Text = "Super Ekonomi"
            Harga.Text = 600000
        End If
        Jumlah.Focus()
    End Sub

    Sub Hapus()
        Kode.Text = ""
        Nama_studio.Text = ""
        Kelas.Text = ""
        Harga.Text = ""
        Jumlah.Text = ""
        Tohar.Text = ""
        Dis.Text = ""
        Tobar.Text = ""
        Dibayar.Text = ""
        Kembalian.Text = ""
    End Sub


    Private Sub Jumlah_KeyPress(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles Jumlah.KeyPress
        If e.KeyChar = Chr(13) Then
            Tohar.Text = Harga.Text * Jumlah.Text
            If Jumlah.Text >= 5 Then
                kon.Text = "10%"
                Dis.Text = 0.1 * Tohar.Text
            Else
                kon.Text = "0%"
                Dis.Text = 0
            End If
            Tobar.Text = Tohar.Text - Dis.Text
            Dibayar.Focus()
        End If

    End Sub

    Private Sub Jumlah_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Jumlah.TextChanged

    End Sub

    Private Sub Bkeluar_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Bkeluar.Click
        Me.Close()
    End Sub

    Private Sub Dibayar_KeyPress(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles Dibayar.KeyPress
        If e.KeyChar = Chr(13) Then
            Kembalian.Text = Dibayar.Text - Tobar.Text
        End If
    End Sub

    Private Sub Dibayar_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Dibayar.TextChanged

    End Sub

    Private Sub Bhapus_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Bhapus.Click
        Call Hapus()
    End Sub
End Class


Semoga Program Sederhana VB.NET Penjualan Tiket Film bisa bermanfaat, dan terimakasih.
wasalamm,,,




0 komentar:

Post a Comment

VB.net :: Program Sederhana VB.NET Penjualan Tiket Film