source code pasien rumah sakit

Source code visual basic
Yang saya tulis disini adalah source code untuk program rumah sakit, tapi yang saya tulis hanyalah sepengetahuan saya semata. (@  @)
Mohon maaf jika banyak kesalahan :
di bawah ini source code nya buatan + editan saya,,hehehhe semoga membantu kamu,,

Public Class Form1

   Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
        Dim control As Windows.Forms.Control
        For Each control In Me.Controls
            If control.Tag = "A" Then
                control.Enabled = False
            End If
Next

    End Sub

    Private Sub btkeluar_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btkeluar.Click
        MsgBox("Anda yakin ..?")
        Me.Close()

    End Sub

    Private Sub btisis_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btisis.Click

        Dim Control As Windows.Forms.Control
        For Each Control In Me.Controls
            Control.Enabled = True

        Next

    End Sub

    Private Sub bthapus_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles bthapus.Click
        tbnama.Text = ""
        rcbalmat.Text = ""
        Cmbdiagnosa.Text = ""
        tbkode.Text = ""
        tbumur.Text = ""
        btisis.Text = ""
        Tbdokter.Text = ""
        Cnbkelas.Text = ""
        lbtgl.Text = ""
        cmbkshatan.Text = ""
        TbruangPRWTN.Text = ""
        tbnoKMr.Text = ""

    End Sub

    Private Sub Cmbdiagnosa_SelectedIndexChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Cmbdiagnosa.SelectedIndexChanged
        If Cmbdiagnosa.SelectedItem = "kanker" Then

            Tbdokter.Text = "drs.samsul"


        ElseIf Cmbdiagnosa.SelectedItem = "penyakit kulit" Then

            Tbdokter.Text = "Drs.sukiman dan kasnanto"

        ElseIf Cmbdiagnosa.SelectedItem = "jantung" Then
            Tbdokter.Text = "Drs.Irwan andriyanto"
        ElseIf Cmbdiagnosa.SelectedItem = "tumor" Then
            Tbdokter.Text = "Drs.sukiman"
        ElseIf Cmbdiagnosa.SelectedItem = "kencing manis&rematik" Then
            Tbdokter.Text = "Drs.sukiman"
        ElseIf Cmbdiagnosa.SelectedItem = "flu burung& flu babi" Then
            Tbdokter.Text = "Drs.sobirin"
        ElseIf Cmbdiagnosa.SelectedItem = "masuk angin" Then
            Tbdokter.Text = "Drs.karno"

        End If
    End Sub

    Private Sub rdlakilaki_CheckedChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles rdlakilaki.CheckedChanged
        If rdlakilaki.Checked Then
            TbruangPRWTN.Text = "ANGGREK"

        End If
    End Sub

    Private Sub rdperempuan_CheckedChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles rdperempuan.CheckedChanged
        If rdperempuan.Checked Then
            TbruangPRWTN.Text = "MAWAR"

        End If
    End Sub

    Private Sub tampilkan_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles tampilkan.Click
        Form2.Show()

    End Sub

    Private Sub Btsimpan_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Btsimpan.Click
        Form2.Visible = True
        Form2.Lbdata.Items.Add(" Tanggal Masuk     : " & Me.lbtgl.Text)
        Form2.Lbdata.Items.Add(" Nama Pasien       : " & Me.tbnama.Text)
        Form2.Lbdata.Items.Add(" Umur              : " & Me.tbumur.Text)
        Form2.Lbdata.Items.Add(" Alamat            : " & Me.rcbalmat.Text)
        Form2.Lbdata.Items.Add(" Diagnosa          : " & Me.Cmbdiagnosa.Text)
        Form2.Lbdata.Items.Add(" Kode Pasien       : " & Me.tbkode.Text)
        Form2.Lbdata.Items.Add(" Kelas Ruang       :" & Me.Cnbkelas.Text)
        Form2.Lbdata.Items.Add(" Ruang Perawatan   : " & Me.TbruangPRWTN.Text)
        Form2.Lbdata.Items.Add(" No Kamar            : " & Me.tbnoKMr.Text)
        Form2.Lbdata.Items.Add(" Dokter               : " & Me.Tbdokter.Text)
        Form2.Lbdata.Items.Add(" Jaminan Kesehatan : " & Me.cmbkshatan.Text)

    End Sub

    Private Sub lbdata_SelectedIndexChanged(ByVal sender As System.Object, ByVal e As System.EventArgs)

    End Sub
End Class

0 komentar: