'How to set iReport page height dynamically when it generate

i'm new for iReport. i'm building a point of sale system using java. to print the receipt i used the irepot. my problem is when i'm generate a report report height is not get reduce or increase dynamically.

for ex : when there are 2 rows in the report report height must be reduce. if there the 50 rows in the report, report height must be increase dynamically.

How can i do that....



Solution 1:[1]

You must put the fields in detail band. This is an basic tutorial: http://jasperforge.org/uploads/publish/ireportwebsite/IR%20Website/ir_design_a_report.html

Regards

Solution 2:[2]

select report > Properties > Ignore pagination = true

<jasperReport 
 xmlns=....
 ...
 ...
 isIgnorePagination="true" 
 >

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 esmoreno
Solution 2