Рамка занимает место даже после применения «Удалить строку, когда пусто» - PullRequest
0 голосов
/ 11 ноября 2019

Я использую рамку внутри рамки. Внутренняя рамка будет отображаться только в том случае, если условие удовлетворяет true. Внутри рамки также есть определенные поля. Проблема, с которой я сталкиваюсь, заключается в том, что, хотя условие ложно и весь кадр не отображается, он по-прежнему отображает пустое пространство.

Я уже установил для параметра «Удалить строку, когда пусто» значение true, но все еще остается пустое пространство. присутствуют.

<band height="201">
    <printWhenExpression><![CDATA[$F{Name}!=null]]></printWhenExpression>
    <frame>
        <reportElement positionType="Float" x="1" y="1" width="573"
            height="200" isRemoveLineWhenBlank="true" />
        <frame>
            <reportElement positionType="Float" x="67" y="0" width="506"
                height="199" isRemoveLineWhenBlank="true" />
            <box>
                <leftPen lineWidth="1.0" />
            </box>
            <textField isStretchWithOverflow="true" isBlankWhenNull="true">
                <reportElement positionType="Float" x="7" y="2" width="474"
                    height="17" isRemoveLineWhenBlank="true" />
                <textElement>
                    <font fontName="Arial" size="12" isBold="true" />
                </textElement>
                <textFieldExpression><![CDATA[$F{Name}]]></textFieldExpression>
            </textField>
            <frame>
                <reportElement positionType="Float" x="0" y="20"
                    width="506" height="151" isRemoveLineWhenBlank="true">
                    <printWhenExpression><![CDATA[$F{RemarkDisplay}.equalsIgnoreCase("FALSE")]]></printWhenExpression>
                </reportElement>
                <box>
                    <leftPen lineWidth="1.0" />
                </box>
                <textField isStretchWithOverflow="true" isBlankWhenNull="true">
                    <reportElement positionType="Float" x="7" y="0"
                        width="38" height="14" isRemoveLineWhenBlank="true" forecolor="#615B5B">
                    </reportElement>
                    <textElement verticalAlignment="Bottom">
                        <font fontName="Arial" size="11" isBold="true" />
                    </textElement>
                    <textFieldExpression><![CDATA[$R{l_Phone}+":"]]></textFieldExpression>
                </textField>
                <textField isStretchWithOverflow="true" isBlankWhenNull="true">
                    <reportElement positionType="Float" x="36" y="106"
                        width="457" height="14" isRemoveLineWhenBlank="true" forecolor="#666666" />
                    <textElement textAlignment="Left" verticalAlignment="Bottom">
                        <font fontName="Arial" size="11" isPdfEmbedded="true" />
                        <paragraph lineSpacing="Single" />
                    </textElement>
                    <textFieldExpression><![CDATA[$F{Rate}!=null?$F{Rate}:" "]]></textFieldExpression>
                </textField>
                <textField isStretchWithOverflow="true" isBlankWhenNull="true">
                    <reportElement positionType="Float" mode="Transparent"
                        x="7" y="106" width="28" height="14" isRemoveLineWhenBlank="true"
                        forecolor="#615B5B" />
                    <textElement textAlignment="Left" verticalAlignment="Bottom">
                        <font fontName="Arial" size="11" isBold="true" isPdfEmbedded="true" />
                        <paragraph lineSpacing="Single" />
                    </textElement>
                    <textFieldExpression><![CDATA[$R{l_Rate}+":"]]></textFieldExpression>
                </textField>
                <textField isStretchWithOverflow="true" isBlankWhenNull="true">
                    <reportElement positionType="Float" x="7" y="121"
                        width="102" height="14" isRemoveLineWhenBlank="true" forecolor="#615B5B" />
                    <textElement textAlignment="Left" verticalAlignment="Bottom">
                        <font fontName="Arial" size="11" isBold="true" isPdfEmbedded="true" />
                        <paragraph lineSpacing="Single" />
                    </textElement>
                    <textFieldExpression><![CDATA[$R{l_ReferenceNumber}+":"]]></textFieldExpression>
                </textField>
                <textField isStretchWithOverflow="true" isBlankWhenNull="true">
                    <reportElement positionType="Float" x="7" y="137"
                        width="38" height="14" isRemoveLineWhenBlank="true" forecolor="#615B5B" />
                    <textElement verticalAlignment="Bottom">
                        <font fontName="Arial" size="11" isBold="true" />
                    </textElement>
                    <textFieldExpression><![CDATA[$R{l_Status}+":"]]></textFieldExpression>
                </textField>
            </frame>
        </frame>
        <textField>
            <reportElement positionType="Float" x="17" y="2" width="50"
                height="14" forecolor="#615B5B">
            </reportElement>
            <textElement>
                <font fontName="Arial" size="11" isBold="true" />
            </textElement>
            <textFieldExpression><![CDATA[$F{Date}]]></textFieldExpression>
        </textField>
    </frame>
</band>

Третий кадр, который использует условие: $ F {RemarkDisplay} .equalsIgnoreCase ("FALSE") не является истинным в моем случае, и это не смещение всех полей кадра, но этоотображение пробела,

Любая помощь, где я иду не так?

Добро пожаловать на сайт PullRequest, где вы можете задавать вопросы и получать ответы от других членов сообщества.
...