ActiveReports(3.0)打印空白页的问题
有没有办法判断一个页面是否有内容?我遇到了一个偶发问题,在我的 4 页报告中,在进入下一页之前,我偶尔会看到一个空白的详细信息部分(显示页眉/页脚)。 我认为发生这种情况是因为我在第三页上有一个子报告,根据其内容,该子报告可能会向下推得太远。
不管怎样,我在想,如果我能确定细节是否为空,我也许就能压制它的创造。
想法、想法、建议?
Is there any way to determine if a page has any content? I am running into a sporadic issue where in my 4-page report I will ocassionally get a blank detail section (header/footer displayed) before going on to the next page.
I think it occurs because I have a sub-report on the 3rd page that might push down a little too far depending on its content.
Anyways, I was thinking if I could determine if the detail was empty, I might be able to supress its creation.
thoughts, ideas, suggestions?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
无法判断该部分是否为空白。但是,您所解释的情况不应该发生。尝试将父报表的详细信息部分的 KeepTogether 设置为 false。如果不是绝对必要,请尝试将组标头上的 GroupKeepTogether 属性设置为 false,看看是否会使其消失。
出现空白页的最常见原因是 LeftMargin+PrintWidth+RightMargin >实际页面宽度
确保这不会影响您。
最后,如果您能够设法一致地重现此内容并向我们发送样本,请将其发布在 ActiveReports 支持论坛,我们中的一位将帮助您解决问题。
There is no way to tell if that section is blank. However, what you're explaining shouldn't happen. Try setting the parent report's Detail section's KeepTogether to false. If it isn't absolutely necessary try setting the GroupKeepTogether property on the group header to false and see if that makes it go away.
The most common reason for a blank page is that the LeftMargin+PrintWidth+RightMargin > Actual Page Width
Make sure this isn't affecting you.
Finally, if you can manage to reproduce this consistently and send us a sample, post it on the ActiveReports support forum and one of us will help you get it resolved.
我发现解决了我遇到的类似问题的一个技巧是迭代报告中的每个部分并告诉其大小以适合内容。
这可能适用于所有情况,也可能不适用于所有情况,并且 ActiveReports 专家可能不会建议,但它确实解决了我遇到的问题。
A hack that I've found that fixed a similar issue I was running into was to iterate over each section in the report and tell it to size to fit the contents.
This may or may not work for all scenarios and would probably not be advised by ActiveReports experts, but it did fix the issue I was running into.
我只需将详细报告可见性设置为 false 即可解决该问题。
I was able to fix the issue just by setting Detail Report visibility to false.