Hello Everybody, Ok I think it is now the appropriate time to ask this questions after all my trials. I have a jar file which has following types of files: File name Directory Structure test.class / makePanel.class /test pic1.gif /images/pic pic2 /images abc.ict / xyz.id /images/pic where xyz.id and abc.ict are simple text files with a change in extension. Now problem is in extracting it... As the documentation goes that I have to use ClassLoader to load same before using.. I tried the following: For Images:
It works. 2. Now problem comes in when I want to read all the files from the directory /image/pic.. In a normal case I was trying the following code snippet...
but failed to retrieve same from jar file with the above concept. if i tried with:
It doesn't work...perhaps the path it is giving is: jar:file:/E:/test/test.jar!/images/pic Can somebody help me in this regard...
Joined: Dec 07, 2001
In a desperate attemp I tried with another set of codes:
Here in above the InputStream object in is null...while all other has some value.. I think I am somewhere missing the concept badly of jar files..can somebody help me... regards, arun