Dim hzxm As String = e.Form.Controls("TextBox1").Value
Dim zyh As String = e.Form.Controls("TextBox2").Value
Dim ssfy As String = e.Form.Controls("TextBox3").Value
Dim gcys As String = e.Form.Controls("ComboBox1").Value
Dim yblx As String = e.Form.Controls("ComboBox2").Value
Dim sslx As String = e.Form.Controls("ComboBox3").Value
Dim qdys As String = e.Form.Controls("ComboBox4").Value
Dim zdys As String = e.Form.Controls("ComboBox5").Value
Dim dyzs As String = e.Form.Controls("ComboBox6").Value
Dim hsdr As String = e.Form.Controls("ComboBox7").Value
Dim hssr As String = e.Form.Controls("CheckedComboBox1").Value
Dim jsr As String = user.name
jsr = jsr.Trim("登","录","账","号","[","]",":"," ")
Dim pbx As WinForm.PictureBox
Dim ssrq As WinForm.DateTimePicker
ssrq = e.Form.Controls("DateTimePicker1")
Dim dr As DataRow
Dim rdo1 As WinForm.RadioButton
Dim rdo2 As WinForm.RadioButton
rdo1 = e.Form.Controls("RadioButton1")
rdo2 = e.Form.Controls("RadioButton2")
If hzxm = "" Then
MessageBox.Show("姓名不能为空!","提示")
ElseIf zyh = "" Then
MessageBox.Show("住院号不能为空!","提示")
ElseIf sslx = "" Then
MessageBox.Show("手术类型不能为空!","提示")
Else
dr = DataTables("患者").Find("[患者姓名] = '" & hzxm & "' ")
If dr Is Nothing Then dr = DataTables("患者信息").AddNew()
dr("住院号") = zyh
dr("手术日期") = ssrq
dr("管床医师") = gcys
dr("医保类型") = yblx
dr("手术类型") = sslx
dr("全刀医师") = qdys
dr("主刀医师") = zdys
dr("第一助手") = dyzs
dr("护士单人") = hsdr
dr("护士双人") = hssr
dr("手术费用") = ssrq
If rdo1.Checked = True Then
dr("是否急诊") = True
Else
dr("是否急诊") = False
End If
DataTables("患者信息").LoadFilter=" [患者姓名] = '" & hzxm & "'"
DataTables("患者信息").Load
DataTables.Save()
e.Form.Controls("TextBox1").Value = ""
e.Form.Controls("TextBox2").Value = ""
e.Form.Controls("TextBox3").Value = ""
e.Form.Controls("ComboBox1").Value = ""
e.Form.Controls("ComboBox2").Value = ""
e.Form.Controls("ComboBox3").Value = ""
e.Form.Controls("ComboBox4").Value = ""
e.Form.Controls("ComboBox5").Value = ""
e.Form.Controls("ComboBox6").Value = ""
e.Form.Controls("ComboBox7").Value = ""
e.Form.Controls("CheckedComboBox1").Value = ""
e.Form.Controls("DateTimePicker1").Value = ""
MessageBox.Show("提交成功!","提示")
End If