Dim A As WinForm.ComboBox = e.Form.Controls("ComboBox1")
Dim B As WinForm.TextBox = e.Form.Controls("TextBox1")
Dim C As WinForm.TextBox = e.Form.Controls("TextBox2")
Dim str1 As String
Dim str2 As String
Dim str3 As String
str1 = A.text
str2 = B.text
str3 = C.text
Dim dr As DataRow = DataTables("表A").SQLFind ("第一列 = '" & str1 & "'")
If dr IsNot Nothing Then
msgbox(str1 & str2 & str3)
If (MessageBox.show("确定绑定?","提示",MessageBoxButtons.YesNo,MessageBoxIcon.Question) = DialogResult.Yes) Then
dr("第二列") = str2
dr("第三列") = str3 红色代码好像值没有改变,没写到数据表里面。
dr("第四列") = "绑定"
msgbox(1)
Else
dr("第二列") = ""
dr("第三列") = ""
dr("第四列") = ""
msgbox(2)
End If
End If