//HelloWorld.java
public class HelloWorld
{
public static void main()
{
System.out.println("Hello World");
}
}
可以编译为.class,但是在运行时
Exception in thread "main" java.lang.NoClassDefFoundError:HelloWorld
然后后面又写了一大堆,最后写:
Could not find the main class:HelloWorld. Program will exit.
//HelloWorld.java
public class HelloWorld
{
public static void main()
{
System.out.println("Hello World");
}
}
可以编译为.class,但是在运行时
Exception in thread "main" jav ...
范文捷 发表于 2010-8-27 23:00
还是不行对所有.class
Exception in thread "main" java.lang.NoClassDefFoundError: ****
Caused by: java.lang.ClassNotFoundException: ****
at java.net.URLClassLoader$1.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClassInternal(Unknown Source)
Could not find the main class: ****. Program will exit.
****指名称