File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Beginning Java and the fly likes Using Apache Commons Configuration Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "Using Apache Commons Configuration" Watch "Using Apache Commons Configuration" New topic

Using Apache Commons Configuration

Dennis Putnam
Ranch Hand

Joined: Feb 03, 2012
Posts: 210
This is my first attempt to use Commons Configuration and I am stuck right out of the box. I am setting up a test app and I don't know if this is my misunderstanding of what it does or something else. To make my environment clear I am using Eclipse and downloaded the configuration library. I then imported it into my project with the Eclipse build configure dialog. In Eclipse I can see the library as a branch of the correct tree. Here is my simple test code:

When I try to initialize 'config' I get a classNotFoundException (line 22). However, when I drill down the tree I can see that class. Can someone see what I am doing wrong? TIA.
Dennis Putnam
Ranch Hand

Joined: Feb 03, 2012
Posts: 210
After some searching I think I am missing a dependency. I think I need the commons exception runtime archive. However, I cannot find where to get it. Am I on the wrong track?
I agree. Here's the link:
subject: Using Apache Commons Configuration
Similar Threads
Reading an XML file using Properties class
Best Way of Accessing Constants
unsatisfied Dependancy exception
can anyone help with this code
Having problems finding mqseries queues in java bean