JasperReport:如何使用参数数据换行

问题描述 投票:0回答:0

我想在不同的单元格中显示参数数据,但在 CSV 中,数据显示在单个单元格中。

<textField>
    <reportElement x="0" y="0" width="200" height="30" />
    <textElement textAlignment="Left" verticalAlignment="Top" />
    <textFieldExpression><![CDATA[$P{data}]</textFieldExpression>
</textField>

我的参数输入:

"Shopping\nBooks\nClothing\Electronics"

我想将其打印在 CSV 中的不同单元格中,但它卡在一个单元格中:

Shopping
Books
Clothing
Electronics
csv jasper-reports
© www.soinside.com 2019 - 2024. All rights reserved.