本文介绍了如何更改SubReport中的RowSource的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述 亲爱的读者, 用于更改主报告的RowSource的VBA代码的语法是: Me.RowSource = TableOrQueryName 但是现在改变SubReport的RowSource的语法: 我认为它必须是这样的: Reports.MasterReportName.SubReportName.RowSource = " TableOrQueryName" 但这不起作用。 这有什么工作语法吗? 坦克可以提供任何帮助。 种类问候, Simon Dear reader, The syntax for the VBA code to change the RowSource of a Master Report is: Me.RowSource = "TableOrQueryName" But now the syntax to change the RowSource of a SubReport: I think it has to be something like this: Reports.MasterReportName.SubReportName.RowSource ="TableOrQueryName" But this is not working. Is there a working syntax for this? Tanks for any help. Kind regards, Simon推荐答案 Reports!MasterReportName.SubReportName.Report.RowS ource =" TableOrQueryName" 注意添加单词Report。这指示Access参考 报告本身,而不是托管它的子报告控件。 Reports!MasterReportName.SubReportName.Report.RowS ource ="TableOrQueryName" Notice the addition of the word Report. This instructs Access to refer tothe report itself, not the subreport control that ''hosts'' it. control, control, 是: is: 这篇关于如何更改SubReport中的RowSource的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!
09-21 12:15