Jasper reports jasper报告中的分页符-组

Jasper reports jasper报告中的分页符-组,jasper-reports,Jasper Reports,我有一份包含一组的报告:columnHeader、columnFooter、title和detail 我希望它在新的一页上。我试过使用isStartNewPage=“true”,keepTogether,然后我试过使用![CDATA[$V{PAGE\u NUMBER}==…]。我达到的最远的一步是当我的columnHeader被打印到几个新页面上时(取决于我的参数值) 有没有关于分页符的建议 <group name="Categorii" isStartNewPage="true

我有一份包含一组的报告:columnHeader、columnFooter、title和detail

我希望它在新的一页上。我试过使用
isStartNewPage=“true”
keepTogether
,然后我试过使用
![CDATA[$V{PAGE\u NUMBER}==…]
。我达到的最远的一步是当我的columnHeader被打印到几个新页面上时(取决于我的参数值)

有没有关于分页符的建议

    <group name="Categorii" isStartNewPage="true">
    <groupHeader>
        <band height="20">
            <textField evaluationTime="Group" evaluationGroup="Categorii" bookmarkLevel="1" isStretchWithOverflow="true">
                <reportElement x="0" y="5" width="208" height="15" style="TableGroup" stretchType="RelativeToTallestObject"/>
                <box leftPadding="10" topPadding="2">
                </box>
                <textElement verticalAlignment="Middle" textAlignment="Left">
                    <font isBold="true"/>
                </textElement> 
                <textFieldExpression class="java.lang.String">"Alte cheltuieli directe"</textFieldExpression>
            </textField>
            <textField isStretchWithOverflow="true" isBlankWhenNull="true">
                <reportElement x="208" y="5" mode="Opaque" width="347" height="15" style="TableGroup" stretchType="RelativeToTallestObject"/>
                <box padding="2">
                </box>
                <textElement verticalAlignment="Top" textAlignment="Right">
                    <font isBold="true"/>
                </textElement>
                <textFieldExpression class="java.lang.String"><![CDATA[""]]></textFieldExpression>
            </textField>
        </band>
    </groupHeader>
    <groupFooter>
        <band height="80">
            <staticText>
                <reportElement mode="Opaque" x="0" y="0" width="208" height="25" style="TableHeader" backcolor="white"/>
                <textElement verticalAlignment="Middle" textAlignment="Right"/>
                <text><![CDATA[]]></text>
            </staticText>  
            <textField isStretchWithOverflow="true" isBlankWhenNull="true">
                <reportElement x="0" y="0" width="208" height="35" style="TableGroup" stretchType="RelativeToTallestObject"/>
                <box padding="2">
                    <topPen lineWidth="0.5"/>
                    <bottomPen lineWidth="0.5"/>
                </box>
                <textElement verticalAlignment="Bottom" textAlignment="Left">
                    <font isBold="true"/>
                </textElement>
                <textFieldExpression class="java.lang.String">"TOTAL CHELT. DIRECTE "</textFieldExpression>
            </textField>
            <staticText>
                <reportElement mode="Opaque" x="208" y="0" width="68" height="25" style="TableHeader" backcolor="white"/>
                <textElement verticalAlignment="Middle" textAlignment="Center"/>
                <text><![CDATA[Mo]]></text>
            </staticText>   
            <textField isStretchWithOverflow="true" isBlankWhenNull="true">
                <reportElement x="208" y="0" width="68" height="35" style="TableGroup" stretchType="RelativeToTallestObject"/>
                <box padding="2">
                    <topPen lineWidth="0.5"/>
                    <bottomPen lineWidth="0.5"/>
                </box>
                <textElement verticalAlignment="Bottom" textAlignment="Right">
                    <font isBold="true"/>
                </textElement>
                <textFieldExpression class="java.math.BigDecimal"><![CDATA[$F{sub_cat_material}]]></textFieldExpression>
            </textField>
            <staticText>
                <reportElement mode="Opaque" x="276" y="0" width="68" height="25" style="TableHeader" backcolor="white"/>
                <textElement verticalAlignment="Middle" textAlignment="Center"/>
                <text><![CDATA[mo]]></text>
            </staticText>  
            <textField isStretchWithOverflow="true" isBlankWhenNull="true">
                <reportElement x="276" y="0" width="68" height="35" style="TableGroup" stretchType="RelativeToTallestObject"/>
                <box padding="2">
                    <topPen lineWidth="0.5"/>
                    <bottomPen lineWidth="0.5"/>
                </box>
                <textElement verticalAlignment="Bottom" textAlignment="Right">
                    <font isBold="true"/>
                </textElement>
                <textFieldExpression class="java.math.BigDecimal"><![CDATA[$F{sub_cat_manopera}]]></textFieldExpression>
            </textField>
            <staticText>
                <reportElement mode="Opaque" x="344" y="0" width="68" height="25" style="TableHeader" backcolor="white"/>
                <textElement verticalAlignment="Middle" textAlignment="Center"/>
                <text><![CDATA[Uo]]></text>
            </staticText>  
            <textField isStretchWithOverflow="true" isBlankWhenNull="true">
                <reportElement x="344" y="0" width="68" height="35" style="TableGroup" stretchType="RelativeToTallestObject"/>
                <box padding="2">
                    <topPen lineWidth="0.5"/>
                    <bottomPen lineWidth="0.5"/>
                </box>
                <textElement verticalAlignment="Bottom" textAlignment="Right">
                    <font isBold="true"/>
                </textElement>
                <textFieldExpression class="java.math.BigDecimal"><![CDATA[$F{sub_cat_utilaj}]]></textFieldExpression>
            </textField>
            <staticText>
                <reportElement mode="Opaque" x="412" y="0" width="68" height="25" style="TableHeader" backcolor="white"/>
                <textElement verticalAlignment="Middle" textAlignment="Center"/>
                <text><![CDATA[to]]></text>
            </staticText>  
            <textField isStretchWithOverflow="true" isBlankWhenNull="true">
                <reportElement x="412" y="0" width="68" height="35" style="TableGroup" stretchType="RelativeToTallestObject"/>
                <box padding="2">
                    <topPen lineWidth="0.5"/>
                    <bottomPen lineWidth="0.5"/>
                </box>
                <textElement verticalAlignment="Bottom" textAlignment="Right">
                    <font isBold="true"/>
                </textElement>
                <textFieldExpression class="java.math.BigDecimal"><![CDATA[$F{sub_cat_transport}]]></textFieldExpression>
            </textField>
            <staticText>
                <reportElement mode="Opaque" x="480" y="0" width="68" height="25" style="TableHeader" backcolor="white"/>
                <textElement verticalAlignment="Middle" textAlignment="Center"/>
                <text><![CDATA[To]]></text>
            </staticText>  
            <textField isStretchWithOverflow="true" isBlankWhenNull="true">
                <reportElement x="480" y="0" width="75" height="35" style="TableGroup" stretchType="RelativeToTallestObject"/>
                <box padding="2">
                    <topPen lineWidth="0.5"/>
                    <bottomPen lineWidth="0.5"/>
                </box>
                <textElement verticalAlignment="Bottom" textAlignment="Right">
                    <font isBold="true"/>
                </textElement>
                <textFieldExpression class="java.math.BigDecimal"><![CDATA[$F{sub_cat_total}]]></textFieldExpression>
            </textField>
            <textField isStretchWithOverflow="true" isBlankWhenNull="true">
                <reportElement x="0" y="35" width="150" height="15" style="TableGroup" stretchType="RelativeToTallestObject"/>
                <box padding="2">
                    <topPen lineWidth="0.5"/>
                    <bottomPen lineWidth="0.5"/>
                </box>
                <textElement verticalAlignment="Bottom" textAlignment="Left">
                    <font isBold="true"/>
                </textElement>
                <textFieldExpression class="java.lang.String">"Cheltuieli indirecte "</textFieldExpression>
            </textField>
            <textField isStretchWithOverflow="true" isBlankWhenNull="true">
                <reportElement x="180" y="35" width="280" height="15" style="TableGroup" stretchType="RelativeToTallestObject"/>
                <box padding="2">
                    <topPen lineWidth="0.5"/>
                    <bottomPen lineWidth="0.5"/>
                </box>
                <textElement verticalAlignment="Bottom" textAlignment="Left">
                    <font isBold="true"/>
                </textElement>
                <textFieldExpression class="java.lang.String">"Io = 5.000% x To"</textFieldExpression>
            </textField>

            <textField isStretchWithOverflow="true" isBlankWhenNull="true">
                <reportElement x="450" y="35" width="105" height="15" mode="Opaque" style="TableData" stretchType="RelativeToTallestObject"/>
                <box padding="2">
                    <topPen lineWidth="0.5"/>
                    <bottomPen lineWidth="0.5"/>
                </box>
                <textElement verticalAlignment="Top" textAlignment="Right">
                    <font isBold="true"/>
                </textElement> 
                <textFieldExpression class="java.math.BigDecimal"><![CDATA[$F{sub_total}]]></textFieldExpression>
            </textField>

            <textField isStretchWithOverflow="true" isBlankWhenNull="true">
                <reportElement x="0" y="50" width="180" height="15" style="TableGroup" stretchType="RelativeToTallestObject"/>
                <box padding="2">
                    <topPen lineWidth="0.5"/>
                    <bottomPen lineWidth="0.5"/>
                </box>
                <textElement verticalAlignment="Bottom" textAlignment="Left">
                    <font isBold="true"/>
                </textElement>
                <textFieldExpression class="java.lang.String">"Profit "</textFieldExpression>
            </textField>
            <textField isStretchWithOverflow="true" isBlankWhenNull="true">
                <reportElement x="180" y="50" width="280" height="15" style="TableGroup" stretchType="RelativeToTallestObject"/>
                <box padding="2">
                    <topPen lineWidth="0.5"/>
                    <bottomPen lineWidth="0.5"/>
                </box>
                <textElement verticalAlignment="Bottom" textAlignment="Left">
                    <font isBold="true"/>
                </textElement>
                <textFieldExpression class="java.lang.String">"Po = 5.000% x (To+Io) "</textFieldExpression>
            </textField>
            <textField isStretchWithOverflow="true" isBlankWhenNull="true">
                <reportElement x="450" y="50" width="105" height="15" mode="Opaque" style="TableData" stretchType="RelativeToTallestObject"/>
                <box padding="2">
                    <topPen lineWidth="0.5"/>
                    <bottomPen lineWidth="0.5"/>
                </box>
                <textElement verticalAlignment="Top" textAlignment="Right">
                    <font isBold="true"/>
                </textElement> 
                <textFieldExpression class="java.math.BigDecimal"><![CDATA[$F{sub_total}]]></textFieldExpression>
            </textField>
            <textField isStretchWithOverflow="true" isBlankWhenNull="true">
                <reportElement x="0" y="65" width="180" height="15" style="TableGroup" stretchType="RelativeToTallestObject"/>
                <box padding="2">
                    <topPen lineWidth="0.5"/>
                    <bottomPen lineWidth="0.5"/>
                </box>
                <textElement verticalAlignment="Bottom" textAlignment="Left">
                    <font isBold="true"/>
                </textElement>
                <textFieldExpression class="java.lang.String">"TOTAL GENERAL pe categorie "</textFieldExpression>
            </textField>
            <textField isStretchWithOverflow="true" isBlankWhenNull="true">
                <reportElement x="180" y="65" width="280" height="15" style="TableGroup" stretchType="RelativeToTallestObject"/>
                <box padding="2">
                    <topPen lineWidth="0.5"/>
                    <bottomPen lineWidth="0.5"/>
                </box>
                <textElement verticalAlignment="Bottom" textAlignment="Left">
                    <font isBold="true"/>
                </textElement>
                <textFieldExpression class="java.lang.String">"Vo = To+Io+Po "</textFieldExpression>
            </textField>
            <textField isStretchWithOverflow="true" isBlankWhenNull="true">
                <reportElement x="450" y="65" width="105" height="15" mode="Opaque" style="TableData" stretchType="RelativeToTallestObject"/>
                <box padding="2">
                    <topPen lineWidth="0.5"/>
                    <bottomPen lineWidth="0.5"/>
                </box>
                <textElement verticalAlignment="Top" textAlignment="Right">
                    <font isBold="true"/>
                </textElement> 
                <textFieldExpression class="java.math.BigDecimal"><![CDATA[$P{total_general}]]></textFieldExpression>
            </textField>
        </band>
    </groupFooter>
</group>

“阿尔特·切尔图耶利董事会”
“直接总费用”
“间接切图耶利”
“Io=5.000%x至”
“利润”
“采购订单=5.000%x(至+Io)”
“普通体育总分类”
“Vo=To+Io+Po”

从JRXML图片中:您缺少
组表达式


如果没有一个合适的jrxml(随时间变化),您将永远不会有分组休息。

您应该发布小jrxml来重现问题+screenshot@AlexK我发布了我所在小组的代码。我想让那个小组进入新的一页。谢谢你。那复制这个问题的小(完整)模板呢?