Newly developer when builds their first java web application with Server (Tomcat) and Eclipse at that time sometimes the developers don’t know how to add the Server after created the java web project. Like, after create the java web project, if developers want to change the Server version or sometimes remove the Server from the project then how can they do.
This is the fixable problem.
Let’s see here how to fix that problem.
STEP-1
Here you can see my project name is “cookieslogins”. Also, can see the red mark cross on the project.
STEP-2
Go to the “Libraries” of the project.
STEP-3
You can see in the “Libraries” Server was not added at that time.
STEP-4
Go to Right Click on the project. Go to “Build Path” -> Then, choose “Configure Build Path” option.
STEP-5
Then, In Java Build Path Select Classpath -> Select “Add Library”.
STEP-6
In Add Library choose Server Runtime Libraries -> Next.
STEP-7
Choose your Apache Tomcat Server which you have downloaded in the Eclipse. -> Finish.
STEP-8
Now can see Server (Apache Tomcat v10.0) added in the Classpath.
STEP-9
Then, Select Apply -> Apply and Close.
STEP-10
We can see Server is added in the Libraries and the red cross on the project is gone too.
Yorumlar