aspose file tools*
The moose likes Applets and the fly likes Load resources from jar file located within a jar Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Java » Applets
Bookmark "Load resources from jar file located within a jar" Watch "Load resources from jar file located within a jar" New topic
Author

Load resources from jar file located within a jar

Phani Chaitanya
Greenhorn

Joined: Jan 16, 2012
Posts: 9
Hi,

I dont know whether this is the right thread to put this question up or not. If not, Admin - please move this query to the right thread.

Im trying to load an applet using Object tag in a jsp. Applet is located in a jar and the required resources for that applet are located in a single jar. The resources jar contains 10 jars approx. required to load the applet. I was able to load the applet if i give all the jars. but was unsuccessful if i make all the resources in to single jar. Here is the code sample that is working




This code is not working


help me.
Paul Clapham
Bartender

Joined: Oct 14, 2005
Posts: 18658
    
    8

You can't access resources which are inside a jar which itself is inside a jar. Not unless you use a specialized classloader which understands that setup -- and using classloaders other than the system classloader would require you to sign your applet.

Since you already have the solution -- don't put your jars inside a jar -- there isn't much more to be said.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Load resources from jar file located within a jar