If e.DataCol.Name = "下发" AndAlso e.DataRow("下发") = True Then Dim nma() As String = {"发文单位","文号","文件名称","文件","发文日期"} 'A表数据来源列 Dim nmb() As String = {"发文单位","文号","文件名称","文件","发文日期"} 'B表数据接收列 Dim dr As DataRow = DataTables("贯彻学习").Find("发文单位='" & e.DataRow("发文单位") & "' and 文号='" & e.DataRow("文号") & "'") If dr Is Nothing Then dr = DataTables("贯彻学习").addnew End If For i As Integer = 0 To nma.Length - 1 dr(nmb(i)) = e.DataRow(nma(i)) Next End If
|