This week's book giveaway is in the Kotlin forum.
We're giving away four copies of Kotlin in Action and have Dmitry Jemerov & Svetlana Isakova on-line!
See this thread for details.
Win a copy of Kotlin in Action this week in the Kotlin forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

configuring jasper reports with struts  RSS feed

 
Jim Colwood
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi All,

I am trying to add a reporting module in my existing web app. I am using Struts & IBatis frameworks in my app.

This is waht I have so far...
In my Actin class...
1. I compile .jrxml & get jasperReport object.
2. create dataSource object by passing a List in JRBeanCollectionDataSource() constructor.
3. get JasperPrint object by calling JasperFillManager.fillReport(jasperReport, parameters, dataSource)
4. create exporter object from JRHtmlExporter class & call exporter.exportReport().
5. forawrd control to the display jsp to display the report.

The problem is...
It doesn't forward to the JSP I specified in struts-config.xml. I think exportReport() method take control & process the request w/o giving control back to struts. I also tried doing all of the above on my display JSP & just forwarding request to this JSP from my action class, but of no use.

Is there an easier way of configuring Jasper Reports with struts? I would appreciate any help.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!