Win a copy of Murach's Python Programming this week in the Jython/Python forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

NoClassDefFoundError in Servlets  RSS feed

 
Amu Hlongwane
Greenhorn
Posts: 14
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello everyonr,

I have a problem with external jar files and the Servlets. I have created a small web app that i want to use external jar file that i have created.i hv put the jar file in set the classpath accordingly. I kno this is right because i get my code compiled succesfully but it gives following exception at run time.

The same jar file works in java app ,but not in servlets .

Any help wil highly be appreciated!

Lvcster.
 
Ben Souther
Sheriff
Posts: 13411
Firefox Browser Redhat VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You didn't tell us anything about the container you're using.

Most containers will ignore your classpath and build their own by looking in a set of directories for classes and jar files. (WEB-INF/classes and WEB-INF/lib, respectively).
 
Ben Souther
Sheriff
Posts: 13411
Firefox Browser Redhat VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
"lvcster",
It looks like you've changed your name to something invalid.
Please see the
JavaRanch Naming Policy

In particular, your display name must be a first and a last name separated by a space character, and must not be obviously fictitious. You can change it here

Thank you for taking care of this.
-Ben
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!