Dim dr As DataRow = e.DataRow
Select Case e.DataCol.Name
Case "文书类别_受理案件通知书","文书类别_起诉或反诉状副本","文书类别_答辩状副本","文书类别_举证通知书","文书类别_传piao","文书类别_出庭通知书","文书类别_其他2","文书类别_其他1"
Dim dr1 = DataTables("数据表").Find("[案号] = '" & e.DataRow("案号") & "'")
If dr1 IsNot Nothing Then
Dim str As String = ""
For Each dr In e.DataTable.Select("[案号] = '" & e.DataRow("案号") & "'", "收寄日期")
dr("邮寄清单") = IIF(dr.IsNull("文书类别_受理案件通知书"),"",dr("收寄日期") & "受理案件通知书" + vbcrlf)
dr("邮寄清单") += IIF(dr.IsNull("文书类别_起诉或反诉状副本"),"",dr("收寄日期") & "起诉或反诉状副本" + vbcrlf)
dr("邮寄清单") += IIF(dr.IsNull("文书类别_答辩状副本"),"",dr("收寄日期") & "答辩状副本" + vbcrlf)
dr("邮寄清单") += IIF(dr.IsNull("文书类别_举证通知书"),"",dr("收寄日期") & "举证通知书" + vbcrlf)
dr("邮寄清单") += IIF(dr.IsNull("文书类别_传piao"),"",dr("收寄日期") & "传piao" + vbcrlf)
dr("邮寄清单") += IIF(dr.IsNull("文书类别_出庭通知书"),"",dr("收寄日期") & "出庭通知书" + vbcrlf)
dr("邮寄清单") += IIF(dr.IsNull("文书类别_其他1"),"",dr("收寄日期") & dr("文书类别_其他1")+vbcrlf)
dr("邮寄清单") += IIF(dr.IsNull("文书类别_其他2"),"",dr("收寄日期") & dr("文书类别_其他2")+vbcrlf)
dr("邮寄清单") = dr("邮寄清单").trimend(vbcrlf)
str &= dr("邮寄清单")
Next
dr1("送达清单") = str
End If
End Select
'-----------------------
Select Case e.DataCol.Name '写入数据表
Case "案号"
Dim dr1 As DataRow
If e.OldValue = Nothing Then
dr1 = DataTables("数据表").Find("[案号] = '" & e.NewValue & "'")
Else
dr1 = DataTables("数据表").Find("[案号] = '" & e.oldvalue & "'")
End If
End Select