2001 JI Open Discussion Posted August 14, 2006 Share Posted August 14, 2006 By: Ilievski Bozidar - bobi1978 empty reports 2002-04-19 02:24Hi. When the report is empty, (i.e. the query returns 0 rows) I don't see nothing with JasperViewer. Can anyone tell me how to get just the TITLE of the report in this case. By: Teodor Danciu - teodord RE: empty reports 2002-05-16 08:01 Hi, This is not a simple problem. It's not clear what sections should we print if we have no records in the data source. This is why for the moment we print nothing. Maybe someone would want to have also the group headers and footers printed. I suggest you test the number of records before generating the report or test the JasperPrint object for content before viewing it. In case of no records, you can get the title (but also the other sections) by using an instance of JREmptyDataSource. I hope it helps. Teodor By: Mihai Gheorghiu - tanethq RE.: empty reports 2002-05-16 09:40So, if the ResultSet is empty, does JasperManager.runReportToPdf output anything? By: Teodor Danciu - teodord RE: RE.: empty reports 2002-05-19 23:36 Hi, It creates a PDF document without any pages in it. An empty one. Thanks, Teodor Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now