phillips1021
-
Posts
4 -
Joined
-
Last visited
Content Type
Profiles
Forum
Events
Featured Visualizations
Knowledge Base
Documentation (PDF Downloads)
Blog
Documentation (Test Area)
Documentation
Dr. Jaspersoft Webinar Series
Security Advisories
Downloads
Posts posted by phillips1021
-
-
I'm able to get the web application demo to run just fine. However, that demo just uses a single report. I need to have a main report and a sub-report in my web application.
But when I add a sub-report to the main report that uses an new JRBeanCollectionDataSource as the datasource expression I get an error:
javax.servlet.ServletException: javax.servlet.ServletException: Error evaluating expression : Source text : new JRBeanCollectionDataSource($F{phones})
The JasperReport main and sub-report works fine in iReport. They also work fine in just a plain java application.
Any help would be greatly appreciated on how to use a sub-report with a main report in a web application.
Post edited by: phillips1021, at: 2008/07/12 22:58
-
I'm having a similar problem getting Struts2, JasperReport, JasperReport plugin for Struts2, and a JasperReport sub-report to work.
Did you ever solver your problem and if so how?
Bruce
-
I finally figured out how to use as the data source for a JasperReport an ArrayList of objects where each object also has an ArrayList as one its fields.
Since this seemed to be a question posted quite frequently and since there did not seem to be a very good tutorial on how to do this (or at least not one easily found), I created an extensive tutorial on my blog.
Here is the URL to blog entry on http://www.brucephillips.name/blog
:
I hope my blog entry will be helpful to others who needed to use an ArrayList as the data source for a JasperReport.
Bruce
JasperReports and Web Application
in Products
Posted
Thanks to some great help from Dave Newton, I was able to figure out how to use Struts2, JasperReports, a main report and a sub-report in my web application.
I blogged about how I got it all to work here:
http://tinyurl.com/5h7nvv
on my blog at http://www.brucephillips.name/blog
.
In that blog entry you can download a complete war file with source code including the .jrxml files.
Bruce