aspose file tools*
The moose likes Other Open Source Projects and the fly likes How to run iReport jrxml from a jsp page Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Products » Other Open Source Projects
Bookmark "How to run iReport jrxml from a jsp page " Watch "How to run iReport jrxml from a jsp page " New topic
Author

How to run iReport jrxml from a jsp page

vanan saravanan
Ranch Hand

Joined: Jun 02, 2006
Posts: 95
Hi i'm a newbie trying to learn something. I downloaded ireport and have designed my report. It connects to the database and retrives the value with no problems. When i build the report i'm able to see it as a Pdf and it works.

My question is how do i link this to a jsp page. Lets say when i click a button the pdf report appears. The only file i seem to have in the folder is classic.jrxml Thank you for your help...
vanan saravanan
Ranch Hand

Joined: Jun 02, 2006
Posts: 95
I downloaded jasperreports-1.2.7-project. Trying out the webapp sample. It required me to download an "ant" tool. Then i did this step

"Once you have ANT installed, launch "ant -p" from the command line in this directory
to learn more about what tasks you could run to build and test the sample."

clean
javac
prepare
viewDesign
viewDesignxml
war

No other instructions were given after this. How do i carry on..
vanan saravanan
Ranch Hand

Joined: Jun 02, 2006
Posts: 95
Ok managed to figure out how to use the ant tool. I have done until "ant prepare"

When i try running the jsp file i get the following error. Why is it so..

C rogram FilesApache Tomcat 4.0workStandalonelocalhost_webappjspcompile$jsp.java:3: Package net.sf.jasperreports.engine not found in import.
import net.sf.jasperreports.engine.*;
^

C rogram FilesApache Tomcat 4.0workStandalonelocalhost_webappjspcompile$jsp.java:4: Class net.sf.jasperreports.engine.util.JRProperties not found in import.
import net.sf.jasperreports.engine.util.JRProperties;
vanan saravanan
Ranch Hand

Joined: Jun 02, 2006
Posts: 95
Ok managed to solve the problem. Did all the steps accordingly.

Until fill report. "The compiled report design was successfully filled with data."

Then the last step, export report. It gives me an error saying

The requested resource (/webapp/servlets/pdf) is not available.

Why is that so.
vanan saravanan
Ranch Hand

Joined: Jun 02, 2006
Posts: 95
Managed to solve the problem, Will post back again if i face any difficulties
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
 
subject: How to run iReport jrxml from a jsp page
 
Similar Threads
work with a lot of reports in a web application
problem with page size printing html jasperreports
passing a parameterize value to ireport from a jsp page
Problem while using Javabean datasource in iReport.
Creating the crystal reports from Java