Reputation: 871
My requirement is to increase the Detail band height dynamically when the text field has more data. Are there any settings to increase to it?
I am using one textField in the Detail band when it has more information (words), it is displaying only some information.
i.e the words are being cut off. Depending on the detail band height the words are displaying. I would like to increase the band height dynamically when the text field has more data.
Upvotes: 27
Views: 43930
Reputation: 1210
@Ehtisham's answer is right. But in newer version of Jaspersoft Studio there is no Stretch with overflow
property. You have to select the overflow textfield and in the Properties, in Text Adjust
select StretchHeight
Text Adjust
select StretchHeight
In the source it will look like this
<textField textAdjust="StretchHeight">
<reportElement positionType="Float" stretchType="RelativeToTallestObject" x="29" y="0" width="501" height="50" uuid="220d14f8-7cee-4315-9cf7-647b7c480735"/>
<textFieldExpression><![CDATA[$F{NAME}]]></textFieldExpression>
</textField>
Upvotes: 0
Reputation: 11
Go to Report level properties. Advanced - Set the Column count and then Print order as Horizontal
Upvotes: 1
Reputation: 339
First select your field and set following properties (third one is most important):
float
Stretch
type: relative to tallest objectStretch
with overflow: true
(checked)Upvotes: 33
Reputation: 4843
Try setting the text field and surround object to Position Type
Float
in the object's properties.
This should let the report expand as the text field grows.
Upvotes: 1