RSS
email
0

Program ATM sederhana

                                           Gambar 1.1


                                           Gambar 1.2


                                           Gambar 1.3


                                           Gambar 1.4



PENJELASAN
- pertama user diminta untuk memilih bank yang diinginkan (Gambar 1.1 dan Gambar 1.2)
- user memasukkan saldo awal setelah memilih bank (Gambar 1.3)
- pilihan simpan uang, pengambilan uang, dan transfer muncul (Gambar 1.4)
- saldo akan tertera pada grupbox "saldo anda saat ini"
- contoh berhasil transfer (Gambar 1.5)

CODE

Public Class Form1
    Dim saldo As Integer
    Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click
        ComboBox1.Visible = False
        Label1.Visible = False
        Button1.Visible = False
        Button2.Visible = False
        Label3.Visible = True
        TextBox1.Visible = True
        Button3.Visible = True
        Select Case ComboBox1.Text
            Case Is = "BNI"
                Label2.Text = "Bank Negara Indonesia"
            Case Is = "Mandiri"
                Label2.Text = "Bank Mandiri"
            Case Is = "BRI"
                Label2.Text = "Bank Rakyat Indonesia"
            Case Is = "BCA"
                Label2.Text = "BCA"
            Case Is = "CitiBank"
                Label2.Text = "CitiBank"
            Case Is = "HSBC"
                Label2.Text = "HSBC"
            Case Else
                MsgBox("Pilih Bank yang tersedia", MsgBoxStyle.Critical, "Warning")

                ComboBox1.Visible = True
                Label1.Visible = True
                Button1.Visible = True
                Button2.Visible = True
                Label3.Visible = False
                TextBox1.Visible = False
                Button3.Visible = False
        End Select



    End Sub

    Private Sub Button3_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button3.Click
        saldo = TextBox1.Text
        Label8.Text = saldo
        Label10.Visible = True
        GroupBox1.Visible = True
        GroupBox2.Visible = True
        Label3.Visible = False
        TextBox1.Visible = False
        Button3.Visible = False
        Label2.Visible = True
        Button7.Visible = True
        Button8.Visible = True

    End Sub

    Private Sub Button4_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button4.Click
        Label8.Text = saldo + tambah.Text
        tambah.Text = ""
        saldo = Label8.Text
    End Sub

    Private Sub Button5_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button5.Click
        Label8.Text = saldo - kurang.Text
        saldo = Label8.Text
        If saldo < 0 Then
            MsgBox("Maaf, saldo anda tidak mencukupi", MsgBoxStyle.Information, "Warning")
            Label8.Text = saldo + kurang.Text
        End If
        kurang.Text = ""

    End Sub

    Private Sub Button6_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button6.Click
        If transfer.Text = "" Then
            MsgBox("Masukan Jumlah Uang Yang Ingin Di Transfer", MsgBoxStyle.Information, "Transfer")
        ElseIf norek.Text = "" Then
            MsgBox("Masukan No.Rekening Yang dituju", MsgBoxStyle.Information, "Transfer")
        Else
            Label8.Text = saldo - transfer.Text
            saldo = Label8.Text
            MsgBox("Saldo anda telah ditransfer", MsgBoxStyle.Information, "Transfer")
            If saldo < 0 Then
                MsgBox("Maaf, saldo anda tidak mencukupi", MsgBoxStyle.Information, "Warning")
                Label8.Text = saldo + transfer.Text
                saldo = Label8.Text
            End If
        End If
        transfer.Text = ""
        norek.Text = ""
       

    End Sub

    Private Sub Button7_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button7.Click
        MsgBox("aza TSI 09")
        Me.Close()
    End Sub

    Private Sub Button1_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles Button1.Click
        MsgBox("aza TSI 09")
        Me.Close()
    End Sub

    Private Sub Button8_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button8.Click
        Label3.Visible = True
        TextBox1.Visible = True
        Button3.Visible = True
        Label10.Visible = False
        GroupBox1.Visible = False
        GroupBox2.Visible = False
        Label2.Visible = False
        Button7.Visible = False
        Button8.Visible = False
        TextBox1.Text = ""
    End Sub
End Class



programnya dapat didownload disini

icn download Pictures, Images and Photos
Read more
 

Friends