运行JB9出现class file version错误问题?求解决

heeppy 2005-12-14 03:44:29
我原本先在机子上装JDK1.5.0,后来才装JB9,里面带有JDK1.4版,而我在

注册表中将运行环境都改成1.5了,用JB9运行时,我选用JDK1.5的,但运行

一般的java程序时就出现以下问题,请问如何解决?请问如何去设置下面

的class file version?
错误如下;
"Server.java":

G:\J2ME\jbwtkwork\server\src\server\Server.java:12: cannot

access java.lang.Object,bad class file: D:\Program

Files\Java\jdk1.5.0\jre\lib\rt.jar

(java/lang/Object.class),class file has wrong version 49.0,

should be 48.0,Please remove or make sure it appears in the

correct subdirectory of the classpath. at line 12
...全文
245 6 打赏 收藏 转发到动态 举报
写回复
用AI写文章
6 条回复
切换为时间正序
请发表友善的回复…
发表回复
crazycy 2005-12-21
  • 打赏
  • 举报
回复
remove the class files have generated, then rebuild source files again
heeppy 2005-12-18
  • 打赏
  • 举报
回复
我有在project---project properties 将jdk设为1.5的,在tools--configure---jdks中也有设1.5version,我还重装了1.5,可还是一样会出现!
?????
crazycy 2005-12-17
  • 打赏
  • 举报
回复
maybe you should install the proper jdk first, and then configure it by tools--configure---jdks

then it would work well
crazycy 2005-12-17
  • 打赏
  • 举报
回复
project---project properties

appear dialog:
choose paths, change jdks to the version you wanted
heeppy 2005-12-16
  • 打赏
  • 举报
回复
还没解决,顶
heeppy 2005-12-15
  • 打赏
  • 举报
回复
顶下

51,411

社区成员

发帖
与我相关
我的任务
社区描述
Java相关技术讨论
javaspring bootspring cloud 技术论坛(原bbs)
社区管理员
  • Java相关社区
  • 小虚竹
  • 谙忆
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧