2001 JI Open Discussion Posted August 17, 2006 Share Posted August 17, 2006 By: Tiger - hntiger Pls help Can't not compileReportToFile in JSP 2002-11-07 17:48Hi, I use Apache Tomcat/4.0.3 and J2SDK 1.4.0. I can run JasperCompileManager.compileReportToFile in java file. But I can't run JasperCompileManager.compileReportToFile in JSP file. When I tried to do it I got follow error message "JRException: Errors were encountered when compiling report design: Note: sun.tools.javac.Main has been deprecated" Please help me to correct this error. Thank you very much Best regards By: Teodor Danciu - teodord RE: Pls help Can't not compileReportToFile in JSP 2002-11-08 13:21 Hi, I don't think this is the entire stack trace. I suspect the report design is not valid or cannot be compiled in Web environment due to classpath problems. This is not the real error. It is just a warning that is displayed when other more important errors are encoutered during compilation. The entire stack trace of the server console would be much more helpful. Thank you, Teodor By: Tiger - hntiger RE: Pls help Can't not compileReportToFile in JSP 2002-11-10 22:37Thank you Teodor, I think may be classpath problem but I don't know why, because: - If I compile xml file to jasper file in java program, then run JasperRunManager.runReportToPdf in ISP to show it, it is OK. - If I compile xml file to jasper file in JSP (JasperCompileManager.compileReportToFile) I get following error: _Thang_gr_op-; _Thang_it_op-; _VBCC_no_checked-(1=1); _Thang_1-09; _Chuky_gr_op-; _Chuky_it_op-; _VBCC_all_checked-(1=1); _Nam_gr_op-; _Nam_it_op-; _Chuky_1-01; _Nam_no_checked-; _Nam_1-2002; _Chuky_no_checked-; _Thang_no_checked-; _VBCC_gr_op-; _VBCC_it_op-OR; _Thang_no_of_items-2; submit-Show; _Chuky_no_of_items-2; _Nam_no_of_items-2; _Thang_all_checked-; reportid-2; _Chuky_all_checked-; _Nam_all_checked-; _VBCC_no_of_items-2; Thong so para _VBCC (1=1) Thong so para _Thang 09 Thong so para _Chuky 01 Thong so para _Nam 2002 {_Chuky=01, _Nam=2002, _VBCC=(1=1), _Thang=09} In duong dan C:smartcarewebappssmartcareWEB-INFlibjasperreports.jar C:smartcarewebappssmartcareWEB-INFclasses C:smartcarewebappssmartcaredatareport compileReportToFile: Sau JRXmlLoaderSourceFile_getParent : C:smartcarewebappssmartcaredatareportcompileReportToFile: Truoc khi tao destFilecompileReportToFile: Sau khi tao destFilecompileReportToFile: Truoc khi dich file dori.jasper.engine.JRException: Errors were encountered when compiling report design: Note: sun.tools.javac.Main has been deprecated. dtsldv.java:4: Package dori.jasper.engine not found in import. import dori.jasper.engine.*; ^ dtsldv.java:5: Package dori.jasper.engine.fill not found in import. import dori.jasper.engine.fill.*; ^ dtsldv.java:17: Superclass JRCalculator of class dtsldv not found. public class dtsldv extends JRCalculator ^ 3 errors, 1 warning . Please find my error and help me to correct it. Thank you very much. By: Teodor Danciu - teodord RE: Pls help Can't not compileReportToFile in JSP 2002-11-11 13:43 Hi, Yes, it is a classpath problem. Tha Java compiler does not find the jasperreports.jar. You have to take a look at the compile.jsp file found in the "webapp" sample to see how you can customize the report compilation process in Web environment, using the JasperReports special system properties. http://jasperreports.sourceforge.net/quick.how.to.html#compile I hope this helps. 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