I am working on eclipse core java projects. I tried to export the project as jar but it is not reading the properties file. ClassNotFound exceptions are generating. My problem is it project contains one folder conf and one file conf.properties. I am reading this file from one of class file. In eclipse i added the conf directory to build path. But jar file fails.
Please check here, it might help you.
Joined: Jun 15, 2009
I tried it, but no hope .
Still i am facing the same problems. i have added Class-Path to conf in manifest file.
Joined: May 14, 2004
Just adding Class-Path will not resolve your issue. Did you go through the post and Java documentation for getResourceAsStream( If you are using this method to read the file) ? The location is goverened by the way you load the properties file.