In MyEclipse BuildPath Plus server lib (Server Runtime)/project import times wrong: The import javax.servlet.http.HttpServletRequest cannot be Resolved

Source: Internet
Author: User

From: http://blog.csdn.net/dingqinghu/article/details/8805922

http://yl-fighting.iteye.com/blog/1409468

After using the MyEclipse, the project under eclipse was copied over and found to prompt Tomcat 7.0 unbound. The server Runtime is missing.


Here's how to fix it:
1,file->new->other->server->server (note that at New, you need to tick show all Wizards), Next, select Apache,tomcat v7.0 Server, Click Finish.
2, Project right-click->properties->java Build path->libraries->add library->server Runtime (myeclipse incompatible)- >next->tomcat v7.0 server->tomcat v7.0 Server
Can.

Project Import times wrong: The import javax.servlet.http.HttpServletRequest cannot be resolved

Error:

The import Javax.servlet cannot be resolved

The import javax.servlet.http.HttpServletRequest cannot be resolved

Description:

We often copy other people's projects to their own here for two times development or reference, sometimes the above error occurs,

In the Eclipse project we imported the project hint HttpServletRequest can not be quoted, will accompany the headache of the small red fork appear.

Accuse:

The specific reason is that we are in the project Web-inf/lib directory under the corresponding package: packages javax.servlet.http caused;

The popular and exact speaking is the lack of tomcat_home\lib under the Servlet-api.jar.

I import someone else's project, he configures the server on someone else's machine, it is generally tomcat, and the libraries of the server will not be copied with the project during the copy, unless someone else has copied the Tomcat library to web-inf\. Lib.

Action:

ADD Library, Server Runtime, Next, Java Build Path, Project--Properties--Select your server-Fi Nish

In MyEclipse BuildPath Plus server lib (Server Runtime)/project import times wrong: The import javax.servlet.http.HttpServletRequest cannot be Resolved

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.