If e.DataCol.Name = "产品" Then e.DataRow("数量") = DataTables("B 表").Compute("Sum(数量)","[产品] = '" & e.NewValue & "'") + DataTables("C 表").Compute("Sum(数量)","[产品] = '" & e.NewValue & "'")End If