Dim nma() As String = {"物供号","系列名","客款号","颜色"} 'A表数据来源列 Dim t As Table = Tables("dbscmx")
For i As Integer = t.TopPosition To t.BottomPosition Dim dr As Row = t.rows(i) Dim r As Row = Tables("生产计划").addnew() Dim str As String = "" For n As Integer = 0 To nma.length -1 str &= dr(nma(n)) & "--" Next str &= t.Compute("sum(订单合计)", "xxx列 = '" & dr("xxx列") & "'") r("排产内容")= str Next