PDA

View Full Version : Exception in main thread: java.lang.NoClassDefFoundError.


sinchana
Apr 23, 2009, 11:27 AM
Hi,
Java program is compiling successfully.while running I am getting the error as Exception in main thread java.lang.NoClassDefFoundError.how to solve this?I have set classpath as c:program files/java/jdk1.5.0_05/jre/tools.jar...
Please reply asap..

ulasad
May 26, 2009, 04:59 AM
I think the coreect path will like this
Files/java/jdk1.5.0_05/bin,
Hope it solves the problem

parthht
Oct 22, 2010, 07:29 AM
I am completely agree with the above answer...

You can also set the environment variabe
PATH: C:\Program Files\Java\jdk1.7.0\bin

OUTPATH:C:\Program Files\Java\jdk1.7.0\lib

tusharghadge
Mar 13, 2011, 10:22 PM
SET PATH=C:\j2sdk1.4.2_05\bin

SET CLASSPATH=C:\j2sdk1.4.2_05\bin

SET JAVA_HOME=C:\j2sdk1.4.2_05