Results 1 to 2 of 2
- 03-06-2009, 04:09 PM #1
Member
- Join Date
- Mar 2009
- Posts
- 3
- Rep Power
- 0
[SOLVED] Apache Commons Properties file exceptions
I'm having trouble implementing the Apache commons library. All I want to do is read a properties file. I'm using the code:
And even thought it's in a try catch block which catches all exceptions, it keeps saying ConfigurationException must be caught or declared to be thrown. So if I wrap it in its own try catch, to catch that exception it says the ConfigurationException is an incompatible type and not throwable.Java Code:Configuration config = new PropertiesConfiguration("setup.properties");
I've read the user guide for apache commons, but that doesn't help me solve the problem. Regardless if I pass PropertiesConfiguration a string or file...same error.
Any ideas?
Ed
- 03-06-2009, 04:24 PM #2
Member
- Join Date
- Mar 2009
- Posts
- 3
- Rep Power
- 0
Similar Threads
-
How to make Apache Commons (StringUtils etc...) work with Eclipse?
By chrvi in forum New To JavaReplies: 3Last Post: 01-29-2012, 10:44 AM -
org.apache.commons.mail.EmailException: Cannot find valid hostname
By Ed in forum Advanced JavaReplies: 3Last Post: 07-25-2011, 03:19 PM -
send email using apache commons email
By jnamendi in forum JavaServer Faces (JSF)Replies: 0Last Post: 10-14-2008, 05:55 PM -
RegExp to remove tag from html file with exceptions
By Daedalus in forum Advanced JavaReplies: 3Last Post: 09-27-2008, 04:43 AM -
FTP private directory problems with org.apache.commons.net.ftp.FTP
By magaupe in forum Advanced JavaReplies: 0Last Post: 09-13-2008, 07:58 PM


LinkBack URL
About LinkBacks
Reply With Quote
Bookmarks