# using ant giving exception NoClassDefFoundError - Eclipse IDE

using ant giving exception NoClassDefFoundError - Eclipse IDE

I am assuming that, If you're building with Eclipse, make sure that the directory where your compiled .class files exists, is in the CLASSPATH, and has the necessary .class files in it.

If you're building with Ant, make sure you see something like this in your build.xml:

<path id="production.class.path">
<pathelement location="${production.classes}"/> <pathelement location="${production.resources}"/>
<fileset dir="\${production.lib}">
<include name="**/*.jar"/>
<exclude name="**/junit*.jar"/>
<exclude name="**/*test*.jar"/>
</fileset>
</path>

Or May be either you don't have JAVA_HOME/bin in your PATH or you downloaded the JRE instead of the JDK. Check the directory where you installed Java and see if your /bin directory has javac.exe in it. If you don't have a /bin, download the JDK and install it.