Dim Result As DialogResult
Result = MessageBox.Show("确定导出?", "提示", MessageBoxButtons.YesNo, MessageBoxIcon.Question,MessageBoxDefaultButton.Button2)
Dim Cols1() As String = {"工作单位","县公司","姓名","性别","身份证号码","文化程度","鉴定等级","申报鉴定工种","鉴定批次","申报性质","备注","照片","是否合格","理论考否","考试性质"}
Dim Cols2() As String = {"工作单位","县公司","姓名","性别","身份证号码","文化程度","鉴定等级","申报鉴定工种","鉴定批次","申报性质","备注","照片","是否合格","理论考否","考试性质"}
For Each dr1 As DataRow In DataTables("审核合格表").Select("[考试性质] = '补考实操' and [考试性质] = '补考潜能' and [考试性质] = '补考两项'")
Dim dr2 As DataRow = DataTables("实操潜能表").Find("身份证号码 = '" & dr1("身份证号码") & "'")
If dr2 Is Nothing Then
dr2 = DataTables("实操潜能表").AddNew
End If
For i As Integer = 0 To Cols1.Length -1
dr2(Cols2(i)) = dr1(Cols1(i))
Next
Next
这段代码错在哪?求帮助!
不报错,点击按钮只能实现“考试性质”=‘补考实操’的人员全部填充过去,另外两种就过不去。