Jump to content
Changes to the Jaspersoft community edition download ×

whats the problem of this code?

Recommended Posts

By: binacse - jatno

whats the problem of this code?

2006-05-10 03:44


<body> Hi, I have Wriiten following code.But it is not working.

package jasperreportsintro;


import java.util.HashMap;

import net.sf.jasperreports.engine.*;

import net.sf.jasperreports.engine.design.*;


public class JasperReportsIntro


public static void main(String[] args)



JasperReport jasperReport;

JasperPrint jasperPrint;




jasperReport = JasperCompileManager.compileReport("jasperreports_demo.jrxml");

jasperPrint = JasperFillManager.fillReport(

jasperReport, new HashMap(), new JREmptyDataSource() );


jasperPrint, "simple_report.pdf");



catch ( JRException e)








But it shows following error? can u give me the solution? Whats the problem of my code? In my code i wanted to generate an PDf file? Please help me.

With regards




Link to comment
Share on other sites

  • Replies 0
  • Created
  • Last Reply

Top Posters In This Topic

Popular Days

Top Posters In This Topic

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 account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Create New...