-- 计算编码问题
哪位大师帮忙看一下,我的代码错在哪了?
Dim dr1 As DataRow = e.DataRow
Select Case e.DataCol.Name
Case "收款合计","预付合计","入库合计","发票合计","返款合计"
If dr1.IsNull("收款合计") OrElse dr1.IsNull("预付合计") OrElse dr1.IsNull("入库合计") OrElse dr1.IsNull("发票合计") OrElse dr1.IsNull("返款合计") Then
dr1("预付余额") = Nothing
dr1("入库余额") = Nothing
dr1("发票余额") = Nothing
dr1("返款余额") = Nothing
Else
dr1("预付余额") = dr1("收款合计") - dr1("预付合计")
dr1("入库余额") = dr1("预付合计") - dr1("入库合计")
dr1("发票余额") = dr1("入库合计") - dr1("发票合计")
dr1("返款余额") = dr1("收款合计") - dr1("返款合计")
End If
End Select