If e.DataCol.Name = "拼音码" Then
If e.DataRow.Isnull("拼音码") Then
e.DataRow("项目类别") = Nothing
e.DataRow("项目名称") = Nothing
e.DataRow("sys_剂量值") = Nothing
e.DataRow("启用") = False
Else
Dim dr As DataRow = DataTables("收费项目").Find("[拼音码] = '" & e.DataRow("拼音码") & "'")
If dr IsNot Nothing Then
e.DataRow("项目类别") = dr("项目类别")
e.DataRow("项目名称") = dr("项目名称")
e.DataRow("sys_剂量值") = dr("规格值")
e.DataRow("启用") = True
Else
MsgBox("项目不存在,请重新输入!",64,"提示")
e.DataRow("项目类别") = Nothing
e.DataRow("项目名称") = Nothing
e.DataRow("sys_剂量值") = Nothing
e.DataRow("拼音码") = Nothing
e.DataRow("启用") = False
End If
End If
End If
If e.DataCol.Name = "追加数量" Then
If e.DataRow("追加数量")>=1 Then
e.DataRow("启用") = True
Else
e.DataRow("追加数量") = Nothing
e.DataRow("启用") = False
MsgBox("数量不能小于1!",64,"提示")
End If
End If
求助1,红色的代码会重复提示2次,怎么能让提示1次?
求助2,上下两组代码均以If e.DataCol.Name = "拼音码" Then开头,如何如何合并到一起?