ProgrammingThis forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
When I try to execute the sample code. Some error occur.
Code :
Quote:
public class Main
{
public static void main(String[] args)
{
String reportSource = "./report/templates/HelloReportWorld.jrxml";
String reportDest = "./report/results/HelloReportWorld.html";
Map<String, Object> params = new HashMap<String, Object>();
java.io.IOException: java.io.IOException: javac: not found
at java.lang.UNIXProcess.<init>(UNIXProcess.java:148)
at java.lang.ProcessImpl.start(ProcessImpl.java:65)
at java.lang.ProcessBuilder.start(ProcessBuilder.java:451)
at java.lang.Runtime.exec(Runtime.java:591)
at java.lang.Runtime.exec(Runtime.java:464)
at net.sf.jasperreports.engine.design.JRJavacCompiler.compileClasses(JRJavacCompiler.java:62)
at net.sf.jasperreports.engine.design.JRAbstractClassCompiler.compileUnits(JRAbstractClassCompiler.java :67)
at net.sf.jasperreports.engine.design.JRAbstractCompiler.compileReport(JRAbstractCompiler.java:190)
at net.sf.jasperreports.engine.design.JRDefaultCompiler.compileReport(JRDefaultCompiler.java:105)
at net.sf.jasperreports.engine.JasperCompileManager.compileReport(JasperCompileManager.java:211)
at net.sf.jasperreports.engine.JasperCompileManager.compileReport(JasperCompileManager.java:144)
at jasperreportsdemoapp.Main.main(Main.java:33)
Yeah. I running all my code from netbeans. But I just face this problem in this project only. So other project is no prolem at all. I running the netbeans in my slackware. I had set the PATH. the problem still the same.
Compiling the file was no any problem. This problem occur when run the project.
Last edited by hunterfighter; 09-11-2006 at 10:23 AM.
You may have two JRE's installed one along with jdk 1.5.0_07 and one here /usr/lib/java/bin:/usr/lib/java/jre/bin, Did you install the jdk seperately or install it as part of netbeans. Also before installation get rid of previous jre that may have come with the distro you are using.
the command java -version will let you know which jre installation is applied to PATH.
Dude, I know what is my problem by follow your guides. I had settle it.
So firstly, I located the java. I means the default java which come with the distro in /usr/lib/java which is link with the JRE.
I delete the link and link it with the JDK that I installed in the earlier time. And it settle my problem.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.