简体   繁体   中英

JasperReports Server: How to fix error if no data available in report?

I have created a report in Jaspersoft Studio with Domain as Datasource and some parameters (fromDate and toDate) to make my report dynamic based on DATE criteria and published in JasperReports Server which works fine - If data is there report loads based on date parameters and If data not available shows "No data found on selected criteria" .

But while loading the report in my application using visualize.js , If data is there report loads based on the selected date parameters, But If data not there, the page keep on loading with an error in console " Uncaught TypeError: Cannot read property 'length' of undefined - in visualize.js:2028 "

For More Information

I have already selected " No-data section " for " When no data " option in report properties and edited nodata field with my static message , which loads fine in Jasperserver but not in my application through visualize js.

您可以通过在JasperSoftStudio报表属性中设置“当没有数据类型时” =“所有部分都没有明细”来避免错误。

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM