-- 作者:ztlyz2004
-- 发布时间:2012/9/20 15:26:00
--
Dim t As Table = Tables("订单") Dim g As Subtotalgroup t.StopRedraw() t.SubtotalGroups.Clear() t.GroupAboveData = False t.TreeVisible = False t.SpillNode = True
g = New Subtotalgroup g.Aggregate = AggregateEnum.Sum g.GroupOn = "日期" g.TotalOn = "数量,金额" g.Caption = "小计 {0}月" g.DateGroup = DateGroupEnum.Month t.SubtotalGroups.Add(g)
g = New Subtotalgroup g.Aggregate = AggregateEnum.Sum g.GroupOn = "日期" g.TotalOn = "数量,金额" g.Caption = "截止 {0}月" g.DateGroup = DateGroupEnum.Month g.upto = True t.SubtotalGroups.Add(g)
g = New Subtotalgroup g.Aggregate = AggregateEnum.Sum g.GroupOn = "产品" g.TotalOn = "数量,金额" g.Caption = "{0} 合计" t.SubtotalGroups.Add(g)
g = New Subtotalgroup g.Aggregate = AggregateEnum.Sum g.GroupOn = "*" g.TotalOn = "数量,金额" g.Caption = "总计" t.SubtotalGroups.Add(g)
t.Subtotal() t.ResumeRedraw() t.ShowCell(t.Rows.Count(True) - 1, 0) \'显示最后一行
|