Reputation: 9519
I want to print the title and footer band of a report even if there is no details row (empty list or null). Is this the default behavior of Jasper Report?
I'm getting an empty blank page instead of only title-footer bands and I cannot understand if there is a problem in my report or if Jasper works like this.
Upvotes: 0
Views: 2803
Reputation: 11
You can use the property whenNoDataType="AllSectionsNoDetail" in the source code.
When we use this property all sections other than detail band will appear when there is no data. By default ,it is whenNoDataType="NoPages" i.e. when the list is empty , the page will be blank.
Upvotes: 0
Reputation: 5113
Set whenNoDataType="AllSectionsNoDetail"
, the default is NoPages
.
In Jaspersoft Studio you can set the attribute in the Report Properties view.
Upvotes: 5