【典型错误】The type java.lang.Object cannot be resolved.
2014-04-24 15:29
281 查看
参考:http://blog.csdn.net/wo519074786/article/details/7697967
The type java.lang.Object cannot be resolved. It is indirectly referenced from
required .class files
当你在Eclipse引用不同版本JDK工程时会发生该问题。由于你开发环境中应用了多个版本的JDK 或JRE导致的。Eclipse会按照最初的开发环境默认选择对应的Jre。如Eclipse上有jdk1.4开发的环境工程,当你在引入高版本jdk1.6开发的工程时,以上问题就出现了。
问题解决的方案如下:
进入window\preferences\java\Installed JREs
按Add --> Browse...--->选择jre安装路劲(我的jre路径是D:\Program Files\Java\jre1.6.0_02)--->OK
找到你的工程右键点击Properties选项 出现对话框后 选择右边的Libraries选项卡 ---> 单击Add 了Library...--->
选择Jre System Library... ---> Next--->选择Alternate Jre 下的对应版本jre --> Finish ---> Ok
以上问题就可解决。
除此之外,android版本的变化也会引起类似问题。
The type java.lang.Object cannot be resolved. It is indirectly referenced from
required .class files
当你在Eclipse引用不同版本JDK工程时会发生该问题。由于你开发环境中应用了多个版本的JDK 或JRE导致的。Eclipse会按照最初的开发环境默认选择对应的Jre。如Eclipse上有jdk1.4开发的环境工程,当你在引入高版本jdk1.6开发的工程时,以上问题就出现了。
问题解决的方案如下:
进入window\preferences\java\Installed JREs
按Add --> Browse...--->选择jre安装路劲(我的jre路径是D:\Program Files\Java\jre1.6.0_02)--->OK
找到你的工程右键点击Properties选项 出现对话框后 选择右边的Libraries选项卡 ---> 单击Add 了Library...--->
选择Jre System Library... ---> Next--->选择Alternate Jre 下的对应版本jre --> Finish ---> Ok
以上问题就可解决。
除此之外,android版本的变化也会引起类似问题。
相关文章推荐
- 【典型错误】The type java.lang.Object cannot be resolved.
- 【典型错误】The type java.lang.Object cannot be resolved.
- 【典型错误】The type java.lang.Object cannot be resolved.
- 【典型错误】The type java.lang.Object cannot be resolved.
- 【典型错误】The type java.lang.Object cannot be resolved.
- eclipse错误:The type java.lang.Object cannot be resolved.
- 导入百度bae项目 “the type java.lang.Object cannot be resolved” 错误的处理
- ECLIPSE导入一个工程报了如下两个错误 (其中一个是The type java.lang.Object cannot be resolved )
- Eclipse error: The type java.lang.Object cannot be resolved. It is indirectly referenced from the required .class files
- The type java.lang.Object cannot be resolved.It is indirectly referenced from required .class files。
- The type java.lang.Object cannot be resolved. It is indirectly referenced from required .class files
- The type java.lang.Object cannot be resolved.It is indirectly referenced from required .class file
- The type java.lang.Object cannot be resolved. It is indirectly referenced from required .class files
- The type java.lang.Object cannot be resolved
- The type java.lang.Object cannot be resolved解决方法
- 出现error:The type java.lang.Object cannot be resolved. It is indirectly referenced from required .cla
- The type java.lang.Object cannot be resolved. It is indirectly referenced from required .class files
- 在Eclipse中遇到The type java.lang.Object cannot be resolved. 解决办法
- The type java.lang.Object cannot be resolved. It is indirectly referenced from required .class files
- The type java.lang.Object cannot be resolved. It is indirectly referenced from required .class files