红色代码导致邮件收到2次。难道重复执行了2次?
Dim jytg As WinForm.RadioButton = e.Form.Controls("RadioButton8")
Dim jywg As WinForm.RadioButton = e.Form.Controls("RadioButton9")
Dim r As Row = Tables("库存管理界面_table27").Current
If e.Sender.Checked = True Then
r("校验结果") = "1"
r("校验日期") = Date.Today
r.save
Dim n As New MailSender
n.Host = "smtp.exmail.qq.com"
n.Account = "factory@bdcom.com.cn"
n.Password = "Encrypt228HqJ4Mg"
n.From = "factory@bdcom.com.cn"
n.AddReceiver("maqiaoli@bdcom.com.cn")
If r("仓库编码") = "15" Then
n.AddReceiver("zhengjiku@bdcom.com.cn")
n.AddReceiver("iqc_inside001@bdcom.com.cn")
End If
If r("仓库编码") = "23" Then
n.AddReceiver("yanglin@bdcom.com.cn")
n.AddReceiver("iqc_inside002@bdcom.com.cn")
End If
If r("仓库编码") = "30" Then
n.AddReceiver("iqc_inside001@bdcom.com.cn")
n.AddReceiver("cy-zd@bdcom.com.cn")
End If
n.Title = "OEM IN管控系统===" & "到货单号:" & r("单据号") & " 物料编码:" & r("存货编码") & " 数量:" & r("数量") & " 仓库编码:" & r("仓库编码") & "---IQC已校验OK请储运入库"
n.C & r("供应商") & vbcrlf & "到货单号:" & r("单据号") & vbcrlf & "物料编码:" & r("存货编码") & vbcrlf & "物料名称:" & r("存货名称") & vbcrlf & "数量:" & r("数量") & vbcrlf & "规格型号:" & r("规格型号") & vbcrlf & "校验日期:" & r("校验日期") & vbcrlf & "特放:" & r("特放")
n.SendAsync()
End If