File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
A friendly place for programming greenhorns!
Big Moose Saloon
Register / Login
Java in General
how to read properties file from different package
Joined: Aug 06, 2012
Aug 07, 2012 15:59:27
I have properties file which is in different package from where i want to access
below code does not works..can any one please help
InputStream in = getClass().getResourceAsStream("/Test/bin/test.properties");
FileInputStream fis = new FileInputStream("/Test/bin/test.properties");
Thanks in Advance !!
Joined: Jul 23, 2008
Aug 07, 2012 21:54:06
This should work
Properties props = new Properties();
With a little knowledge, a
cast iron skillet
is non-stick and lasts a lifetime.
subject: how to read properties file from different package
location of a property file
reading from property file
Adding to property files...
Error reading properties file
File Not Found Exception While Reading Properties File
All times are in JavaRanch time: GMT-6 in summer, GMT-7 in winter
| Powered by
Copyright © 1998-2014