This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes Beginning Java and the fly likes regarding jar file in web application Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "regarding jar file in web application" Watch "regarding jar file in web application" New topic
Author

regarding jar file in web application

subodh gupta
Ranch Hand

Joined: Jul 23, 2007
Posts: 203
not sure this is the right fourm for the question

the problem is i am having a web application and some helper classes and servlet class files what i did is made the jar of all the class file and placed them in the WEB-INF/lib/ folder the application picks up the servlet files but shows error class not found in case of helper classes while is i place the exploded package structure in classes folder everything works fine.


http://subodh-gupta.blogspot.com
Guido Sautter
Ranch Hand

Joined: Dec 22, 2004
Posts: 142
If you're generating the jar file form eclipse IDE, you might want to check the jardesc file to make sure your helper classes get exported. In addition, you can open your jar with WinZip and check what's really in it ... otherwise, no idea.
subodh gupta
Ranch Hand

Joined: Jul 23, 2007
Posts: 203
no problem their it is having all the class files...
Vijitha Kumara
Bartender

Joined: Mar 24, 2008
Posts: 3816

Is your classes get called from the servlet? Then are there import statements correctly, and is final JAR file contain the package structure correctly?


SCJP 5 | SCWCD 5
[How to ask questions] [Twitter]
subodh gupta
Ranch Hand

Joined: Jul 23, 2007
Posts: 203
ya servlet is not giving any error only when i am returning to jsp them the error is thrown of DTO

BUt is imports where wrong then it would have been the same case for classes folder also...

but still for confirmation they are alright thanks
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: regarding jar file in web application
 
Similar Threads
Jar Files Extracting On Compile
import error in JSP, with J2EE
Using CachedRowSet
how to let Java class in jar files in lib folder to access class in the web application?
jar files