在eclipse中编译时出现了Can not find the main class. Program will exit.
我晕吖.终于在CSDN中问到了答案。在此多谢[color=darkred]yinyuan1987[/color]。
下面引用他的答案。
[color=darkblue]解决 Can not find the main class. Program will exit. 难题
运行时跳出can not find the main class,program will exit!
出现这个错误是由于你的jdk版本与eclipse高版本配置造成的,
解决如下:
点击 窗口->首选项
点击编译器,把“编译器一致性级别”从5.0改成1.4试试吧
( 我觉得如果安装的是 JDK 1.5.x,那么可以选择5.0,至少我是这么做的,而且成功了。)
当然这里只是给你说的是版本不匹配的问题
建议使用jdk6.0来配eclipse3.4 [/color]
我晕吖.终于在CSDN中问到了答案。在此多谢[color=darkred]yinyuan1987[/color]。
下面引用他的答案。
[color=darkblue]解决 Can not find the main class. Program will exit. 难题
运行时跳出can not find the main class,program will exit!
出现这个错误是由于你的jdk版本与eclipse高版本配置造成的,
解决如下:
点击 窗口->首选项
点击编译器,把“编译器一致性级别”从5.0改成1.4试试吧
( 我觉得如果安装的是 JDK 1.5.x,那么可以选择5.0,至少我是这么做的,而且成功了。)
当然这里只是给你说的是版本不匹配的问题
建议使用jdk6.0来配eclipse3.4 [/color]