【问题标题】:displaying data based on if condition in a birt report在 birt 报告中根据 if 条件显示数据
【发布时间】:2012-10-10 11:26:26
【问题描述】:

我需要在birt report 中显示几个基于if condition 的值。有什么办法吗?
我使用 XML 作为datasource,所以如果标签不为空,我想在报告中显示它。
这是我需要在报告中添加的 xml 示例

<wr:if><wr:out/></wr:if><wr:if><wr:out/></wr:if><wr:if><wr:out/></wr:if>

这里的&lt;wr:out/&gt; 对应于我用作数据集的 XML 中的标签。

我想知道如何在 birt 报告中显示这些数据?

【问题讨论】:

    标签: java jakarta-ee reporting birt


    【解决方案1】:

    您可以分配属性可见性

    <list-property name="visibility">
      <structure>
         <property name="format">all</property>
         <expression name="valueExpr" type="javascript">your evaluation here</expression>
      </structure>
    </list-property>
    

    当表达式的计算结果为真时,元素被隐藏。

    看看这个教程

    http://digiassn.blogspot.com.au/2007/03/birt-hide-report-table-when-no-data-is.html

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多