在主报表页脚中引用子报表控件 [英] Referencing Subreport Control in Main Report Footer

查看:79
本文介绍了在主报表页脚中引用子报表控件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

Access 2003:子报表控件(位于子报表页脚中的总计算文本框)在主报表页脚中作为总计引用时不显示所有记录的总数 - 仅显示一个记录金额。当我单独打开子报表时,它总计查询所提取的所有记录的总和 - 这就是我想要的。主报表页脚中引用的文本框仅显示一个记录金额。为什么主报告页脚中的总数是这样做的?我解决了以前正确引用#Name的语法问题? #错误?错误。我已经尝试将我的小计移动到组页脚并将总计保留在主报告的报告页脚中,看它是否有所作为,但它没有。如果我使子报表页脚可见,则在查看主报表时,它不会添加所有记录,而是重复每个记录数量,就像报表是连续表单一样。我真的不知道这个问题是不是因为语法?,控件放在报告部分?或分组?任何想法都将非常感激。

Access 2003: A subreport control (sum total calculated textbox located in the subreport report footer) does not show total of all records when referenced as a total in the main report footer - only shows one record amount. When I open the subreport alone, it totals the sum of all the records which the query pulls - which is what I want. The referenced textbox in the main report footer only shows one record amount. Why is the total in the main report footer doing this? I solved previous problem of proper referencing syntax which was giving #Name? #Error? errors. I''ve tried moving my sub-totals to the group footer and kept the grand total in the report footer of the main report to see if it made a difference, but it hasn''t. If I make the subreport report footer visible, then when viewing the main report it is not adding all the records either, but repeating each record amount as if the report is a continuous form. I really don''t know if this problem is because of syntax?, where the controls are placed in the report sections?, or grouping? Any ideas would be much appreciated.

推荐答案

如果我理解正确,你使用总和在子表单中进行计算控制并得到答案,当你试图通过时它是主要形式你在主窗体中得到一个不同的(错误的)答案,但在子表格中得到了正确的结果。


如果这是正确的,请告诉我。如果是我有解决方案。


例如

If I understand correctly you do a calculated control in your sub form using the sum and get an answer and when you try to pass it to the main form you are getting a different (wrong) answer in your main form but a correct result in the subform.

Let me know if this is correct. if it is I have a solution.

For example


Access 2003:子报表控件(总和)位于子报表页脚中的总计算文本框)在主报表页脚中作为总计引用时不显示所有记录的总数 - 仅显示一个记录金额。当我单独打开子报表时,它总计查询所提取的所有记录的总和 - 这就是我想要的。主报表页脚中引用的文本框仅显示一个记录金额。为什么主报告页脚中的总数是这样做的?我解决了以前正确引用#Name的语法问题? #错误?错误。我已经尝试将我的小计移动到组页脚并将总计保留在主报告的报告页脚中,看它是否有所作为,但它没有。如果我使子报表页脚可见,则在查看主报表时,它不会添加所有记录,而是重复每个记录数量,就像报表是连续表单一样。我真的不知道这个问题是不是因为语法?,控件放在报告部分?或分组?任何想法将不胜感激。
Access 2003: A subreport control (sum total calculated textbox located in the subreport report footer) does not show total of all records when referenced as a total in the main report footer - only shows one record amount. When I open the subreport alone, it totals the sum of all the records which the query pulls - which is what I want. The referenced textbox in the main report footer only shows one record amount. Why is the total in the main report footer doing this? I solved previous problem of proper referencing syntax which was giving #Name? #Error? errors. I''ve tried moving my sub-totals to the group footer and kept the grand total in the report footer of the main report to see if it made a difference, but it hasn''t. If I make the subreport report footer visible, then when viewing the main report it is not adding all the records either, but repeating each record amount as if the report is a continuous form. I really don''t know if this problem is because of syntax?, where the controls are placed in the report sections?, or grouping? Any ideas would be much appreciated.


嗨谢谢。子报表位于主报表的详细信息部分中。子报表分别提取了两条记录,金额分别为R1,500和R1,000。如果我自己打开子报表,总和(在子报表的报表页脚中)会添加两个金额并正确获取R2,500。我在主报告的组页脚中引用了一个文本框到子报告页脚中的总计= [Leases Test 2 subreport] .Report![Subreport Total],但主报告只显示R1,000,而不是总计R2,500。如果我将子报表页脚设置为可见,则在主报表中,它会在每条记录下再次复制每个记录金额。它与强制页面或部分有什么关系吗?我很难过,明天我有一个截止日期。要回溯一个litte,主要报告是租户租赁时间表,子报告是租金上涨,我想添加以增加租金金额以获得2月份的总收入。如果我想出来,那么我可以继续进行预测考虑升级。感谢您的帮助。
Hi thanks. The subreport is in the detail section of the main report. The subreport is pulling two records with amounts R1,500 and R1,000 respectively. If I open the subreport on its own the sum (which is in the report footer of the subreport) adds the two amounts and gets R2,500 correctly. I have referenced a textbox in the main report''s group footer to the summed total in the subreport footer =[Leases Test 2 subreport].Report![Subreport Total], but the main report only shows R1,000, and not the R2,500 total. If I set the subreport footer as visible, then in the main report it duplicates each record amount again underneath each record. Does it have anything to do with force pages or sections? I''m so stumped with this, and I have a deadline for tomorrow. To back-track a litte, the main report is a tenant lease schedule, and the subreport is rent escalations which I want to add to add to rent amounts to get total income for month Feb. If I figure this out then I can get on to doing forecasts taking the escalations into account. Thanks for your help.



您好,谢谢。子报表位于主报表的详细信息部分中。子报表分别提取了两条记录,金额分别为R1,500和R1,000。如果我自己打开子报表,总和(在子报表的报表页脚中)会添加两个金额并正确获取R2,500。我在主报告的组页脚中引用了一个文本框到子报告页脚中的总计= [Leases Test 2 subreport] .Report![Subreport Total],但主报告只显示R1,000,而不是总计R2,500。如果我将子报表页脚设置为可见,则在主报表中,它会在每条记录下再次复制每个记录金额。它与强制页面或部分有什么关系吗?我很难过,明天我有一个截止日期。要回溯一个litte,主要报告是租户租赁时间表,子报告是租金上涨,我想添加以增加租金金额以获得2月份的总收入。如果我想出来,那么我可以继续进行预测考虑升级。谢谢你的帮助。
Hi thanks. The subreport is in the detail section of the main report. The subreport is pulling two records with amounts R1,500 and R1,000 respectively. If I open the subreport on its own the sum (which is in the report footer of the subreport) adds the two amounts and gets R2,500 correctly. I have referenced a textbox in the main report''s group footer to the summed total in the subreport footer =[Leases Test 2 subreport].Report![Subreport Total], but the main report only shows R1,000, and not the R2,500 total. If I set the subreport footer as visible, then in the main report it duplicates each record amount again underneath each record. Does it have anything to do with force pages or sections? I''m so stumped with this, and I have a deadline for tomorrow. To back-track a litte, the main report is a tenant lease schedule, and the subreport is rent escalations which I want to add to add to rent amounts to get total income for month Feb. If I figure this out then I can get on to doing forecasts taking the escalations into account. Thanks for your help.



据我所知,您尝试做的事情(引用子报表上的计算控件)不适用于报表,只能使用表单。

我的建议是创建一个单独的查询来计算你需要的总数,并根据该查询建立主报告。

As far as I can remember, the thing you are trying to do (referencing calculated controls on Subreport) is not working with reports, only with forms.
My advice here is to create a separate query calculating the totals you need, and base the main report on that query.


这篇关于在主报表页脚中引用子报表控件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆