问题描述
我有一个带有子报表的报表,我无法将子报表拉伸到带高度,请帮帮我! 子报表不会延伸到波段高度,如下所示(示例)
jrxml 文件:https://pastebin.com/BF2nfjBu
<subreport>
<reportElement stretchType="RelativeToBandHeight" x="460" y="0" width="340" height="16" isPrintWhenDetailOverflows="true" uuid="c5783955-245e-4d93-938c-57ed43e2e3a5"/>
<dataSourceExpression><![CDATA[$F{form21_subreport}]]></dataSourceExpression>
<subreportExpression><![CDATA[$P{sub_report_names}.get("form21_techreq_subreport")]]></subreportExpression>
</subreport>
解决方法
<subreport>
<reportElement stretchType="ContainerHeight" ...
RelativeToBandHeight
已弃用,可能正在被使用中的 jasper 库忽略。