如何在datareport中实现每页的小计***在线等待****

kingbear2000 2002-10-20 01:04:46
我有一数据表其中有一数据段:
如:
单据号码 实收数量
如何在每一页中实现对实收数量的合计。
并且在最后一计实现总计
...全文
39 16 打赏 收藏 转发到动态 举报
写回复
用AI写文章
16 条回复
切换为时间正序
请发表友善的回复…
发表回复
TT008 2002-11-06
  • 打赏
  • 举报
回复
用VB的DATAREPORT实现
PRINTER也可以但想实现预览比较难
kingbear2000 2002-11-05
  • 打赏
  • 举报
回复
楼上的兄弟你所说的是用pcl语言或是printer对象是吗?
kingbear2000 2002-11-04
  • 打赏
  • 举报
回复
哪就是说要事先自已设定每页显示的记录数或者是超过了每页设定的高度之后才可以读出此数。
kingbear2000 2002-11-04
  • 打赏
  • 举报
回复
能实现在程序中动态改变吗,产生每页的小计,例如这页所有某字段的和
TT008 2002-11-04
  • 打赏
  • 举报
回复
Dim HSS As String

HSS = Val(DataReport1.Sections("DT1").Controls("SS1").Caption) + Val(DataReport1.Sections("DT1").Controls("SS2").Caption) + _
Val(DataReport1.Sections("DT1").Controls("SS3").Caption) + Val(DataReport1.Sections("DT1").Controls("SS4").Caption) + _
Val(DataReport1.Sections("DT1").Controls("SS5").Caption) + Val(DataReport1.Sections("DT1").Controls("SS6").Caption) + _
Val(DataReport1.Sections("DT1").Controls("SS7").Caption) + Val(DataReport1.Sections("DT1").Controls("SS8").Caption) + _
Val(DataReport1.Sections("DT1").Controls("SS9").Caption) + Val(DataReport1.Sections("DT1").Controls("SS10").Caption) + _
Val(DataReport1.Sections("DT1").Controls("SS11").Caption) + Val(DataReport1.Sections("DT1").Controls("SS12").Caption) + _
Val(DataReport1.Sections("DT1").Controls("SS13").Caption) + Val(DataReport1.Sections("DT1").Controls("SS14").Caption) + _
Val(DataReport1.Sections("DT1").Controls("SS15").Caption) + Val(DataReport1.Sections("DT1").Controls("SS16").Caption) + _
Val(DataReport1.Sections("DT1").Controls("SS17").Caption) + Val(DataReport1.Sections("DT1").Controls("SS18").Caption) + _
Val(DataReport1.Sections("DT1").Controls("SS19").Caption) + Val(DataReport1.Sections("DT1").Controls("SS20").Caption) + _
Val(DataReport1.Sections("DT1").Controls("SS21").Caption) + Val(DataReport1.Sections("DT1").Controls("SS22").Caption) + _
Val(DataReport1.Sections("DT1").Controls("SS23").Caption) + Val(DataReport1.Sections("DT1").Controls("SS24").Caption) + _
Val(DataReport1.Sections("DT1").Controls("SS25").Caption) + Val(DataReport1.Sections("DT1").Controls("SS26").Caption) + _
Val(DataReport1.Sections("DT1").Controls("SS27").Caption) + Val(DataReport1.Sections("DT1").Controls("SS28").Caption) + _
Val(DataReport1.Sections("DT1").Controls("SS29").Caption) + Val(DataReport1.Sections("DT1").Controls("SS30").Caption)

这只是标签的合计
你还要把数据的值赋给标签
语句如下:
DataReport1.Sections("DT1").Controls("HS1").Caption = Adodc1.Recordset.Fields(1)

TT008 2002-11-04
  • 打赏
  • 举报
回复
可以
不过
我用这个办法实现的是税务报表的定点打印
每打印一张就要按一下打印按钮
kingbear2000 2002-10-31
  • 打赏
  • 举报
回复
静候佳音!
kingbear2000 2002-10-25
  • 打赏
  • 举报
回复
楼上的兄弟,请问如果实现可以给段例子吗?马上给分
TT008 2002-10-24
  • 打赏
  • 举报
回复
datareport没有这个功能
只能用标签
在程序中用代码去计算好
再将值给予标签
kingbear2000 2002-10-23
  • 打赏
  • 举报
回复
大家都误解了我的意思,我是要每一页的小计数,再加最后一页的总计
nebular 2002-10-22
  • 打赏
  • 举报
回复
datafield都设为实收数量
nebular 2002-10-22
  • 打赏
  • 举报
回复
在PAGEFOOTER中增加统计字段FUNCTION TEXTBOX(SUM),在REPORTFOOTER增加统计字段,也是FUNCTION TEXTBOX(SUM)。不必建立分组。
yaoylguest 2002-10-22
  • 打赏
  • 举报
回复
up
kingbear2000 2002-10-21
  • 打赏
  • 举报
回复
即每页的小计数
kingbear2000 2002-10-20
  • 打赏
  • 举报
回复
如何实现,我只想计算出这一页的合计数
chenyu5188 2002-10-20
  • 打赏
  • 举报
回复
在数据环境设计器中创建分组。

809

社区成员

发帖
与我相关
我的任务
社区描述
VB 多媒体
社区管理员
  • 多媒体
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧