[opencms-dev] PROPERTIES files cannot be found?

Ralf B ambiesense at gmx.de
Thu Nov 20 23:20:02 CET 2003


Hi,

I have a properties file in my jar and put in under
Tomcat/webapps/opencms/WEB-INF/lib/mystuff.jar
Inside the jar the properties file is under /res/myconfig.properties.

In my code I try to access it with the following code:


Properties p = new Properties();
try {
  p.load(new FileInputStream("res/myconfig.properties"));
} catch (IOException e) {e.printStackTrace();}


but it cannot be found. The java classes in this jar file work fine. What is
wrong here. I expect that Tomcat does include all the jar files and start
the path from the root of each jar file. It should therefore find the resource
file...

Any idea?

Ralf

-- 
NEU FÜR ALLE - GMX MediaCenter - für Fotos, Musik, Dateien...
Fotoalbum, File Sharing, MMS, Multimedia-Gruß, GMX FotoService

Jetzt kostenlos anmelden unter http://www.gmx.net

+++ GMX - die erste Adresse für Mail, Message, More! +++




More information about the opencms-dev mailing list