Reading
Hi,
I am trying to read a properties file
in a java class which will be used as a bean for a JSP page . But I can not read properties file and it is saying "File Not Found" . I am able to read the file if I give fullpath or if I keep that file in tomcat/bin/ . Is there any other solution ?
Regards,
RaviShankar
[351 byte] By [
ravish.k] at [2007-9-26 2:05:11]

Thank you Madhav .
I am placing the "properties" file in the same directory as of .class file of bean . That is /ROOT/WEB-INF/classes/ .
I can read the properties file if I give the path as "/usr/local/tomcat/webapps/ROOT/WEB-INF/classes/xxx.properties " . But I can not rad the file if I give "xxx.properties" or "/ROOT/WEB-INF/classes/xxx.properties" .
> But I can not rad the file if I give
> "xxx.properties" or
> "/ROOT/WEB-INF/classes/xxx.properties" .
If you want to use the relative path like:
"xxx.properties", then the properties file
should be in the /ROOT folder and NOT under the
classes folder. Also, you should know that any file
under WEB-INF/ folder is private. Thought
you should know this.
regds. :)
- madhav