Re: Why do I get java.lang.NoClassDefFoundError or java.lang.ClassNotFoundException ............
Posted By:
Anonymous
Posted On:
Monday, February 20, 2006 06:37 AM
The problem, which I could see, during runtime the servlet trying to access some class but it is not available.
First check what external classes/JARS this servlet is dependent on.
You need to put these classes under
%CONTEXT-ROOT%/WEB-INF/Classes(Servlet directory) or
If the dependent classes availble to you as JAR then put it inside %CONTEXT-ROOT%/WEB-INF/lib/xyz.jar
Remember the container needs to access these classes during runtime!
Hope this helps!!!
Re: Why do I get java.lang.NoClassDefFoundError or java.lang.ClassNotFoundException ............
Posted By:
santosh_pahariya
Posted On:
Sunday, February 19, 2006 03:44 AM
whenever u get this error you should first confirm ur classpath.if you are getting again and again try to set classpath once again with following syntax on command prompt
set classpath=%classpath%;your foldername;.;
for example:-
c:javaprogram>setpath=%classpath%;c:javaprogram;.;