Java

Moderators: zibadian
Number of threads: 7818
Number of posts: 18218

This Forum Only
Post New Thread
Single Post View       Linear View       Threaded View      f

Report
java Posted by anithananduri on 10 Apr 2009 at 4:12 AM
why i am getting the following error while running javac command from console

C:\>javac
Exception in thread "main" java.lang.NoClassDefFoundError: com/sun/tools/javac
Caused by: java.lang.ClassNotFoundException: com.sun.tools.javac.Main
at java.net.URLClassLoader$1.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClassInternal(Unknown Source)

Report
Re: java Posted by madhu_naru on 20 Apr 2009 at 1:53 AM
Send the source code that you are compiling. May be mistake in defining a class.
Report
Re: java Posted by madhu_naru on 20 Apr 2009 at 1:54 AM
Send the source code that you are compiling. May be mistake in defining a class.
Report
Re: java Posted by Tommittaja on 23 Apr 2009 at 11:35 AM
javac is a command that compiles a code to be compiled. for example: javac code.java. then there is java. for example java code. that for contrast, runs the code ;D
Report
Re: java Posted by Aphillios on 4 May 2009 at 6:15 AM
But if it's having problems compiling, then wouldn't it not work at runtime?
Report
Re: java Posted by CodeSucker on 4 May 2009 at 5:28 PM
no - he's saying that typing 'javac' alone into the prompt isn't productive. add the name of the file

javac mycode.java





 

Recent Jobs

Official Programmer's Heaven Blogs
Web Hosting | Browser and Social Games | Gadgets

Popular resources on Programmersheaven.com
Assembly | Basic | C | C# | C++ | Delphi | Flash | Java | JavaScript | Pascal | Perl | PHP | Python | Ruby | Visual Basic
© Copyright 2011 Programmersheaven.com - All rights reserved.
Reproduction in whole or in part, in any form or medium without express written permission is prohibited.
Violators of this policy may be subject to legal action. Please read our Terms Of Use and Privacy Statement for more information.
Operated by CommunityHeaven, a BootstrapLabs company.