...
>Can anyone tell me how can I acces to the files archivied to jar file
>with the rest of the code??
Assuming the resources are in a Jar on the application's
classpath, it is as simple as..
URL theResourcePath =
obj.getClass().getResource("/path/to/properties.prop");
'obj' can be any Object (or subclass) instance, but
getResource() might fail if it is called by the root class
loader.

Signature
Andrew Thompson
http://www.athompson.info/andrew/
yaaros@gmail.com - 16 Aug 2007 13:06 GMT
> yaa...@gmail.com wrote:
>
[quoted text clipped - 16 lines]
>
> Message posted viahttp://www.javakb.com
Ok that give me a url to resource but how can I read from this path.
When I using
catToRes.listFiles(new FileFilter(){
public boolean accept(File pathname) {
if (pathname.isFile() && pathname.getName().endsWith(".tpl"))
return true;
return false;
}
});
it's return me null?? I'm beginner in that field so please explain me
it as simple as it possible. I add that all files are XML format and I
have to read all of them from resource catalog.
>Can anyone tell me how can I acces to the files archivied to jar file
>with the rest of the code??
see http://mindprod.com/jgloss/resource.html

Signature
Roedy Green Canadian Mind Products
The Java Glossary
http://mindprod.com