码迷,mamicode.com
首页 > 编程语言 > 详细

1,eclipse导入项目jdk版本不一样解决方案 2,java报javax.servlet.jsp cannot be resolved to a type

时间:2019-09-22 23:28:05      阅读:115      评论:0      收藏:0      [点我收藏+]

标签:next   href   --   blog   target   logs   移除   detail   com   

一:eclipse导入项目jdk版本不一样解决方案

参考博文:

https://www.cnblogs.com/chenmingjun/p/8472885.html

选中项目右键 --> Properties --> Build Path --> 选中Libraries一栏,移除(Remove)这个库选项,

  然后添加新的库选项:

  Add Library... --> JRE System Library --> next --> Execution environment --> Environments... --> 选择JavaSE-9(jdk-9.0.4) --> Apply and Close。

  或者直接右键 JRE System Library[JavaSE-1.7] --> Properties --> Execution environment --> Environments... --> 选择JavaSE-9(jdk-9.0.4) --> Apply and Close。

二:java报javax.servlet.jsp cannot be resolved to a type

参考博文:https://blog.csdn.net/weixin_37997251/article/details/80701897

这个错误可能是服务器自带的servlet库未导入的原因。右键项目属性,转到Targeted Runtimes,选择一个服务器,例如Tomcat,单击应用,可能就可以解决。

 

1,eclipse导入项目jdk版本不一样解决方案 2,java报javax.servlet.jsp cannot be resolved to a type

标签:next   href   --   blog   target   logs   移除   detail   com   

原文地址:https://www.cnblogs.com/smartisn/p/11569807.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!