If User.IsRole("经办人") Then
For Each r As Row In Tables("HTB1").Rows
If r("XZH") = True Then
Dim fdr As DataRow = DataTables("XMJDB1").Find("HTBH = '" & r("HTBH") & "' and ND is null and yf is null")
If fdr IsNot Nothing Then
Dim nma() As String = { "XMLB","XMBM","XMMC","HTBH","HTMC","KSJM","KSMC","FYDL","HTFYLB","HTJE","LJZFGCK","分项名称","YZFYFK","YFJK" } 'A表数据来源列
Dim nmb() As String = { "XMLB","XMBM","XMMC","HTBH","HTMC","KSJM","KSMC","FYDL","FYLB","HTJE","LJYFJDK","分项名称","YFGCK","GCJK" } 'B表数据接收列
Dim dr As DataRow = DataTables("XMJDB1").AddNew
For i As Integer = 0 To nma.Length - 1
dr(nmb(i)) = r(nma(i))
Next
End If
End If
Next
End If
[此贴子已经被作者于2015/3/27 16:00:01编辑过]