Search code examples
jasper-reportssubreport

How to not print a subreport if has no data on Jasper report?


I've a master report with several subreports. My JSON datasource, may, or may not, have some content to fill an specific subreport. So, I would like to not show these subreport, not even blank pages. Which is my current situation. I can print something into the No Data band, however I'm not sure how this would help me. Is there any way of doing this ?


Solution

  • Use the property isRemoveLineWhenBlank="true"

    In JasperReports Studio

    enter image description here