Dim g As New GroupTableBuilder("统计表2", DataTables("泵人档案"))
g.Groups.AddDef("泵工基础工资_年月","年月")
g.Totals.AddDef("泵工基础工资_杨坤怀")
g.Totals.AddDef("泵工基础工资_熊寿春")
g.Totals.AddDef("泵工基础工资_袁文杰")
g.Totals.AddDef("泵工基础工资_田进军")
g.Totals.AddDef("泵工基础工资_董泽明")
g.Totals.AddDef("泵工基础工资_许永明")
g.Totals.AddDef("泵工基础工资_董培")
g.Totals.AddDef("泵工基础工资_许银朋")
g.Totals.AddDef("泵工基础工资_杨永照")
g.Totals.AddDef("泵工基础工资_张建聪")
g.Totals.AddDef("泵工基础工资_张磊")
g.Totals.AddDef("泵工基础工资_任伟君")
g.Totals.AddDef("泵工基础工资_李建伟")
g.Totals.AddDef("泵工基础工资_杨昆奇")
g.Totals.AddDef("泵工基础工资_毕文涛")
g.Totals.AddDef("泵工基础工资_张进标")
g.Totals.AddDef("泵工基础工资_杨士民")
g.Totals.AddDef("泵工基础工资_李旋")
g.Totals.AddDef("泵工基础工资_杨建荣")
g.Totals.AddDef("泵工基础工资_毕忠诚")
g.Totals.AddDef("泵工基础工资_李正栋")
g.Filter = "[泵工基础工资_年月] = 201905"
Tables("泵送明细_Table8").DataSource = g.BuildDataSource()
DataTables("泵送明细_Table6").DataRows.Clear()
For Each adr As DataRow In DataTables("泵送明细_Table8").DataRows
If adr.IsNull("年月") = False Then
For Each adc As DataCol In DataTables("泵送明细_Table8").DataCols
If adc.Name.StartsWith("泵工基础工资") AndAlso adr.IsNull(adc.Name) = False Then
Dim bdr As DataRow = DataTables("泵送明细_Table6").AddNew()
bdr("第一列") = adr("年月")
'bdr("第二列") = adr("")
bdr("第三列") = adr(adc.Name)
End If
Next
End If
Next
MainTable = Tables("泵送明细_Table6")
With DataTables("泵送明细_Table6")
.DataCols("第一列").Caption = "年月"
.DataCols("第三列").Caption = "基础工资"
.BuildHeader()
End With