弄了个hello world程序,运行正常,不会报错。
请教下高手,为什么呀?
9 个解决方案
#1
什么都没贴出来,怎么会知道什么问题。
#2
代码没问题的,选run的时候直接报错:
Thread [main] (Suspended (exception ClassNotFoundException))
URLClassLoader$1.run() line: 366
URLClassLoader$1.run() line: 355
AccessController.doPrivileged(PrivilegedExceptionAction<T>, AccessControlContext) line: not available [native method]
Launcher$ExtClassLoader(URLClassLoader).findClass(String) line: 354
Launcher$ExtClassLoader(ClassLoader).loadClass(String, boolean) line: 423
Launcher$AppClassLoader(ClassLoader).loadClass(String, boolean) line: 410
Launcher$AppClassLoader.loadClass(String, boolean) line: 308
Launcher$AppClassLoader(ClassLoader).loadClass(String) line: 356
LauncherHelper.checkAndLoadMain(boolean, int, String) line: 480
Thread [main] (Suspended (exception ClassNotFoundException))
URLClassLoader$1.run() line: 366
URLClassLoader$1.run() line: 355
AccessController.doPrivileged(PrivilegedExceptionAction<T>, AccessControlContext) line: not available [native method]
Launcher$ExtClassLoader(URLClassLoader).findClass(String) line: 354
Launcher$ExtClassLoader(ClassLoader).loadClass(String, boolean) line: 423
Launcher$AppClassLoader(ClassLoader).loadClass(String, boolean) line: 410
Launcher$AppClassLoader.loadClass(String, boolean) line: 308
Launcher$AppClassLoader(ClassLoader).loadClass(String) line: 356
LauncherHelper.checkAndLoadMain(boolean, int, String) line: 480
#3
看看文件名和类名一样不
#4
类似下面这些都设置过:
变量名 classpath
变量值 .;%JAVA_HOME%\lib;%JAVA_HOME%\lib\dt.jar;%JAVA_HOME%\lib\tools.jar
变量名 path
变量加的值 %JAVA_HOME%\bin;%JAVA_HOME%\jre\bin;
变量名 classpath
变量值 .;%JAVA_HOME%\lib;%JAVA_HOME%\lib\dt.jar;%JAVA_HOME%\lib\tools.jar
变量名 path
变量加的值 %JAVA_HOME%\bin;%JAVA_HOME%\jre\bin;
#5
#6
看了下,一样的。
#7
clear下,重新编译试试
#8
不断地复制文件,现在可以run了,但是debug还是报错。到底是什么引起这个错误?有没有办法查到啊?
#9
告诉你一个万能的办法,查API!
#1
什么都没贴出来,怎么会知道什么问题。
#2
代码没问题的,选run的时候直接报错:
Thread [main] (Suspended (exception ClassNotFoundException))
URLClassLoader$1.run() line: 366
URLClassLoader$1.run() line: 355
AccessController.doPrivileged(PrivilegedExceptionAction<T>, AccessControlContext) line: not available [native method]
Launcher$ExtClassLoader(URLClassLoader).findClass(String) line: 354
Launcher$ExtClassLoader(ClassLoader).loadClass(String, boolean) line: 423
Launcher$AppClassLoader(ClassLoader).loadClass(String, boolean) line: 410
Launcher$AppClassLoader.loadClass(String, boolean) line: 308
Launcher$AppClassLoader(ClassLoader).loadClass(String) line: 356
LauncherHelper.checkAndLoadMain(boolean, int, String) line: 480
Thread [main] (Suspended (exception ClassNotFoundException))
URLClassLoader$1.run() line: 366
URLClassLoader$1.run() line: 355
AccessController.doPrivileged(PrivilegedExceptionAction<T>, AccessControlContext) line: not available [native method]
Launcher$ExtClassLoader(URLClassLoader).findClass(String) line: 354
Launcher$ExtClassLoader(ClassLoader).loadClass(String, boolean) line: 423
Launcher$AppClassLoader(ClassLoader).loadClass(String, boolean) line: 410
Launcher$AppClassLoader.loadClass(String, boolean) line: 308
Launcher$AppClassLoader(ClassLoader).loadClass(String) line: 356
LauncherHelper.checkAndLoadMain(boolean, int, String) line: 480
#3
看看文件名和类名一样不
#4
类似下面这些都设置过:
变量名 classpath
变量值 .;%JAVA_HOME%\lib;%JAVA_HOME%\lib\dt.jar;%JAVA_HOME%\lib\tools.jar
变量名 path
变量加的值 %JAVA_HOME%\bin;%JAVA_HOME%\jre\bin;
变量名 classpath
变量值 .;%JAVA_HOME%\lib;%JAVA_HOME%\lib\dt.jar;%JAVA_HOME%\lib\tools.jar
变量名 path
变量加的值 %JAVA_HOME%\bin;%JAVA_HOME%\jre\bin;
#5
#6
看了下,一样的。
#7
clear下,重新编译试试
#8
不断地复制文件,现在可以run了,但是debug还是报错。到底是什么引起这个错误?有没有办法查到啊?
#9
告诉你一个万能的办法,查API!