If e.DataCol.Name = "分配人员" Then For Each dr1 As DataRow In DataTables("表A").datarows Dim nm As String = dr1("姓名") Dim dr2 As DataRow = DataTables("表B").Find("分配人员 = '" & nm & "' Or 分配人员 Like '" & nm & ",*' Or 分配人员 Like '*," & nm & "'") If dr2 IsNot Nothing Then dr1("是否分配工作") = "是" Else dr1("是否分配工作") = Nothing End If Next End If