The superclass "javax.servlet.http.HttpServlet" was not found on the Java Build Path

新建WEB项目出现如下错误,可以这样来修正,

The superclass "javax.servlet.http.HttpServlet" was not found on the Java Build Path

进入Window-preference,选择Server-Runtime Environment,

选择Add,在弹出页面上,选择本机已经安装好的Tomcat版本,next,并指定路径。

 

window-show view-server,选择添加server,把刚才添加的tomcat加入到此server中,这个时候项目中会多出来一个servers项目

 

项目属性,build path,library,add library,选择 server runtime,确定,错误取消。

posted @ 2017-07-12 18:33  陆敏技  阅读(294)  评论(0)    收藏  举报
Web Counter
Coupon for Contacts