Hey,guys,I installed JDK 5.0 today,and I added the variable to the class path: C:\Program Files\Java\jdk1.5.0_09\lib;C:\Program Files\Java\jdk1.5.0_09\lib\tools.jar; then I added the variable to the path: C:\Program Files\Java\jdk1.5.0_09\bin;
but..when I run a HelloJAVA through cmd,I got this: java.lang.NoClassDefFoundError:HelloJAVA,could somebody tell me what`s wrong with it?
you should not add the lib directory of the JDK and tools.jar to your CLASSPATH. Just remove the CLASSPATH environment variable. You do not need to set it. If it is not set, Java will by default look in the current directory for class files.