Programming Tutorials

Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/commons/logging/LogFactory

By: Emiley J. in Java Tutorials on 2008-02-11  

Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/commons/logging/LogFactory 

As always the NoClassDefFoundError is caused due to classpath problems or missing jar files.
In this case, This is caused when the commons-logging-1.1.1.jar file is not in your path.

Follow these steps to solve this problem.

  1. Download the commons-logging-1.1.1.jar file or later version from the following url.
  2. http://commons.apache.org/proper/commons-logging/download_logging.cgi  (download and extract the jar files in your computer)
  3. Add the commons-logging-1.1.1.jar file to your 'lib' folder in your project if you are using an IDE like netbeans or add it to your classpth if you are doing it manually
  4. Rebuild your project and run.





Add Comment

* Required information
1000

Comments

No comments yet. Be the first!

Most Viewed Articles (in Java )

Latest Articles (in Java)