📄 frm_outpat.vb
字号:
Me.TextBox17.Location = New System.Drawing.Point(80, 56)
Me.TextBox17.Name = "TextBox17"
Me.TextBox17.Size = New System.Drawing.Size(72, 20)
Me.TextBox17.TabIndex = 7
Me.TextBox17.Text = ""
Me.TextBox17.TextAlign = System.Windows.Forms.HorizontalAlignment.Center
'
'TextBox16
'
Me.TextBox16.BackColor = System.Drawing.SystemColors.Info
Me.TextBox16.Location = New System.Drawing.Point(80, 16)
Me.TextBox16.Name = "TextBox16"
Me.TextBox16.Size = New System.Drawing.Size(72, 20)
Me.TextBox16.TabIndex = 6
Me.TextBox16.Text = ""
Me.TextBox16.TextAlign = System.Windows.Forms.HorizontalAlignment.Center
'
'Label25
'
Me.Label25.Location = New System.Drawing.Point(8, 88)
Me.Label25.Name = "Label25"
Me.Label25.Size = New System.Drawing.Size(80, 16)
Me.Label25.TabIndex = 4
Me.Label25.Text = "Care Charges"
'
'Label24
'
Me.Label24.Location = New System.Drawing.Point(8, 160)
Me.Label24.Name = "Label24"
Me.Label24.Size = New System.Drawing.Size(64, 16)
Me.Label24.TabIndex = 3
Me.Label24.Text = "Others"
'
'Label23
'
Me.Label23.Location = New System.Drawing.Point(8, 56)
Me.Label23.Name = "Label23"
Me.Label23.Size = New System.Drawing.Size(64, 16)
Me.Label23.TabIndex = 2
Me.Label23.Text = "Physician"
'
'Label22
'
Me.Label22.Location = New System.Drawing.Point(8, 24)
Me.Label22.Name = "Label22"
Me.Label22.Size = New System.Drawing.Size(48, 16)
Me.Label22.TabIndex = 1
Me.Label22.Text = "Ward"
'
'TextBox11
'
Me.TextBox11.BackColor = System.Drawing.SystemColors.Info
Me.TextBox11.Location = New System.Drawing.Point(64, 16)
Me.TextBox11.Name = "TextBox11"
Me.TextBox11.Size = New System.Drawing.Size(56, 20)
Me.TextBox11.TabIndex = 1
Me.TextBox11.Text = ""
'
'Label16
'
Me.Label16.Location = New System.Drawing.Point(8, 24)
Me.Label16.Name = "Label16"
Me.Label16.Size = New System.Drawing.Size(48, 16)
Me.Label16.TabIndex = 0
Me.Label16.Text = "Slip No"
'
'Button2
'
Me.Button2.BackColor = System.Drawing.SystemColors.ControlLight
Me.Button2.Location = New System.Drawing.Point(248, 584)
Me.Button2.Name = "Button2"
Me.Button2.TabIndex = 7
Me.Button2.Text = "Find Slip"
'
'Button3
'
Me.Button3.BackColor = System.Drawing.SystemColors.ControlLight
Me.Button3.Location = New System.Drawing.Point(336, 584)
Me.Button3.Name = "Button3"
Me.Button3.Size = New System.Drawing.Size(64, 23)
Me.Button3.TabIndex = 8
Me.Button3.Text = "Clear"
'
'Button4
'
Me.Button4.BackColor = System.Drawing.SystemColors.ControlLight
Me.Button4.Location = New System.Drawing.Point(568, 584)
Me.Button4.Name = "Button4"
Me.Button4.Size = New System.Drawing.Size(64, 23)
Me.Button4.TabIndex = 9
Me.Button4.Text = "Cancel"
'
'Label8
'
Me.Label8.Location = New System.Drawing.Point(8, 48)
Me.Label8.Name = "Label8"
Me.Label8.Size = New System.Drawing.Size(64, 16)
Me.Label8.TabIndex = 10
Me.Label8.Text = "Patient ID"
'
'TextBox6
'
Me.TextBox6.BackColor = System.Drawing.SystemColors.Info
Me.TextBox6.Location = New System.Drawing.Point(72, 40)
Me.TextBox6.MaxLength = 8
Me.TextBox6.Name = "TextBox6"
Me.TextBox6.Size = New System.Drawing.Size(56, 20)
Me.TextBox6.TabIndex = 12
Me.TextBox6.Text = ""
Me.ToolTip1.SetToolTip(Me.TextBox6, "The Patient's ID")
'
'TextBox15
'
Me.TextBox15.Location = New System.Drawing.Point(656, 288)
Me.TextBox15.Name = "TextBox15"
Me.TextBox15.TabIndex = 13
Me.TextBox15.Text = ""
Me.TextBox15.Visible = False
'
'TextBox26
'
Me.TextBox26.Location = New System.Drawing.Point(656, 312)
Me.TextBox26.Name = "TextBox26"
Me.TextBox26.TabIndex = 14
Me.TextBox26.Text = ""
Me.TextBox26.Visible = False
'
'frm_outpat
'
Me.AutoScaleBaseSize = New System.Drawing.Size(5, 13)
Me.BackColor = System.Drawing.SystemColors.InactiveCaptionText
Me.ClientSize = New System.Drawing.Size(650, 616)
Me.Controls.Add(Me.TextBox26)
Me.Controls.Add(Me.TextBox15)
Me.Controls.Add(Me.TextBox6)
Me.Controls.Add(Me.Label8)
Me.Controls.Add(Me.Button4)
Me.Controls.Add(Me.Button3)
Me.Controls.Add(Me.Button2)
Me.Controls.Add(Me.GroupBox2)
Me.Controls.Add(Me.GroupBox1)
Me.Controls.Add(Me.Label2)
Me.Controls.Add(Me.PictureBox1)
Me.Controls.Add(Me.Label1)
Me.Controls.Add(Me.Button9)
Me.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedToolWindow
Me.Icon = CType(resources.GetObject("$this.Icon"), System.Drawing.Icon)
Me.MaximizeBox = False
Me.MinimizeBox = False
Me.Name = "frm_outpat"
Me.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen
Me.Text = "PrisLogix's PIS"
Me.GroupBox1.ResumeLayout(False)
Me.GroupBox2.ResumeLayout(False)
Me.GroupBox8.ResumeLayout(False)
Me.GroupBox7.ResumeLayout(False)
Me.GroupBox6.ResumeLayout(False)
Me.GroupBox5.ResumeLayout(False)
Me.GroupBox4.ResumeLayout(False)
Me.GroupBox3.ResumeLayout(False)
Me.ResumeLayout(False)
End Sub
#End Region
Dim currentTime As Date
#Region "CODE STARTS HERE"
Dim MyConnection As New OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:\PIS.mdb")
Dim MyCommand
Dim e As Exception
Dim MyCommand2
Dim MyReader As OleDbDataReader
Dim MyReader2 As OleDbDataReader
Dim dbset As New DataSet
Dim dataA
Dim ptype As String
Function disablefields()
TextBox1.Enabled = False
TextBox2.Enabled = False
TextBox3.Enabled = False
TextBox4.Enabled = False
TextBox5.Enabled = False
TextBox7.Enabled = False
TextBox8.Enabled = False
TextBox9.Enabled = False
TextBox10.Enabled = False
TextBox12.Enabled = False
TextBox13.Enabled = False
TextBox14.Enabled = False
'TextBox15.Enabled = False
TextBox16.Enabled = False
TextBox17.Enabled = False
TextBox18.Enabled = False
TextBox19.Enabled = False
TextBox20.Enabled = False
TextBox21.Enabled = False
TextBox22.Enabled = False
TextBox23.Enabled = False
TextBox24.Enabled = False
ComboBox1.Enabled = False
ComboBox2.Enabled = False
ComboBox3.Enabled = False
ComboBox4.Enabled = False
ComboBox5.Enabled = False
End Function
Function enablefields()
TextBox1.Enabled = True
TextBox2.Enabled = True
TextBox3.Enabled = True
TextBox4.Enabled = True
TextBox5.Enabled = True
TextBox7.Enabled = True
TextBox8.Enabled = True
TextBox9.Enabled = True
TextBox10.Enabled = True
TextBox12.Enabled = True
TextBox13.Enabled = True
TextBox14.Enabled = True
'TextBox15.Enabled = True
TextBox16.Enabled = True
TextBox17.Enabled = True
TextBox18.Enabled = True
TextBox19.Enabled = True
TextBox20.Enabled = True
TextBox21.Enabled = True
TextBox22.Enabled = True
TextBox23.Enabled = True
TextBox24.Enabled = True
ComboBox1.Enabled = True
ComboBox2.Enabled = True
ComboBox3.Enabled = True
ComboBox4.Enabled = True
ComboBox5.Enabled = True
End Function
Function clearfields()
TextBox1.Text = ""
TextBox2.Text = ""
TextBox3.Text = ""
TextBox4.Text = ""
TextBox5.Text = ""
TextBox7.Text = ""
TextBox8.Text = ""
TextBox9.Text = ""
TextBox10.Text = ""
TextBox12.Text = ""
TextBox13.Text = ""
TextBox14.Text = ""
'TextBox15.Text = ""
TextBox16.Text = ""
TextBox17.Text = ""
TextBox18.Text = ""
TextBox19.Text = ""
TextBox20.Text = ""
TextBox21.Text = ""
TextBox22.Text = ""
TextBox23.Text = ""
TextBox24.Text = ""
ComboBox1.Text = ""
ComboBox2.Text = ""
ComboBox3.Text = ""
ComboBox4.Text = ""
ComboBox5.Text = ""
TextBox6.Text = ""
TextBox11.Text = ""
End Function
Function getno()
MyConnection.Open()
MyCommand = New OleDbCommand("SELECT * FROM outbill", MyConnection)
MyReader = MyCommand.ExecuteReader()
While MyReader.Read
TextBox15.Text = MyReader("slipno")
End While
MyConnection.Close()
MyReader.Close()
MyCommand.dispose()
End Function
Function disablebuttons()
Button10.Enabled = False
Button12.Enabled = False
Button13.Enabled = False
End Function
Function fillform()
MyConnection.Open()
MyCommand = New OleDbCommand("SELECT * FROM outpat WHERE outcode = '" & TextBox6.Text & "'", MyConnection)
MyReader = MyCommand.ExecuteReader()
While MyReader.Read
TextBox1.Text = MyReader("fname")
TextBox2.Text = MyReader("lname")
ComboBox1.Text = MyReader("gender")
ComboBox3.Text = MyReader("status")
TextBox3.Text = MyReader("address")
TextBox4.Text = MyReader("phone")
TextBox7.Text = MyReader("age")
TextBox5.Text = MyReader("birthday")
TextBox10.Text = MyReader("religion")
TextBox9.Text = MyReader("nationality")
ComboBox2.Text = MyReader("ward")
ComboBox4.Text = MyReader("physician")
End While
MyReader.Close()
MyCommand.dispose()
MyCommand = New OleDbCommand("SELECT * FROM outbill WHERE outcode = '" & TextBox6.Text & "'", MyConnection)
MyReader = MyCommand.ExecuteReader()
While MyReader.Read
TextBox11.Text = MyReader("slipno")
TextBox16.Text = MyReader("wardc")
TextBox17.Text = MyReader("phyc")
TextBox18.Text = MyReader("carec")
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -