Crystal Reports - 如果页面有 0 条记录,则禁止页面标题 [英] Crystal Reports - Suppress a Page Header if the page has 0 records

查看:14
本文介绍了Crystal Reports - 如果页面有 0 条记录,则禁止页面标题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如果页面没有数据记录,我想隐藏页眉.

I'd like to suppress a page header if the page has no data records.

备注

  • 可能仍需要显示该页面才能显示组或报表页脚.
  • 我对当前页面的报告的详细信息部分没有记录的情况感兴趣.我指的是组的所有详细信息记录都已显示,但组页脚换到下一页的情况.

推荐答案

假设您已为组页脚选中 Keep Together,请尝试在节专家的页眉节的条件抑制公式中输入以下内容:

Assuming you have Keep Together checked for the group footer, try entering the following in the conditional suppress formula for the page header section in the section expert:

OnLastRecord or {GROUP FIELD NAME} <> Next({GROUP FIELD NAME})

其中 {GROUP FIELD NAME} 是分组字段的名称.

where {GROUP FIELD NAME} is the name of the grouping field.

OnLastRecord 必须在公式中排在第一位,因为如果报表的最后一页没有明细记录(这样页眉应该被隐藏),那么 Next({GROUP FIELD NAME})评估为 NULL,其后出现的所有条件也都评估为 NULL.

OnLastRecord must come first in the formula, because if the last page of the report has no detail records (so that the page header should be suppressed), then Next({GROUP FIELD NAME}) evaluates as NULL and all conditions that come after it are also evaluated as NULL.

这篇关于Crystal Reports - 如果页面有 0 条记录,则禁止页面标题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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