`

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

 
阅读更多
eclipse好久之前做的java项目,今天打开发现许多jsp页面有如下错误:
The superclass "javax.servlet.http.HttpServlet" was not found on the Java Build Path

如果没有添加Tomcat Server ,需手动添加一下(不过我已经添加过了)
project->Java Build Path->Libraries-> Add Libray->Server Runtime ->Tomcat Server
继续查找原因
Windows->Preferences->Server->Runtime Environments->add->Apache Tomcat v7.0->next 找到相应tomcat7.0的安装路径(这个我也添加过了)
不过在点击我已配置过的Tomcat Server,发现了下面信息:
The specified Tomcat installation directory does not exist.

指定Tomcat的安装目录不存在
原来是换了电脑后,重新放置了Tomcat的安装位置,重新Edit下
还是不行?
把项目从eclipse里面删掉

在把刚从eclipse里刚删的项目import回来

完美解决!
  • 大小: 27.9 KB
  • 大小: 43.7 KB
  • 大小: 17.8 KB
  • 大小: 29.5 KB
分享到:
评论

相关推荐

    eclipse纠错.txt

    EClipse:web项目中某一.jps页面忽然出现错误,鼠标点上去为:The superclass "javax.servlet.http.HttpServlet" was not found on the Java Build Path. 一招解决!

    一个简单的servlet容器

    Servlet容器是Web应用程序的核心组成部分,它负责管理和执行Servlet,Servlet是一种Java编程接口,用于扩展服务器的功能。本主题将深入探讨“一个简单的Servlet容器”的实现,参考自《深入剖析Tomcat》这本书的第二...

    Eclipse+Tomcat+环境配置

    1. 使用`New Class`向导,输入类名`HelloWorld`,在`Superclass`中填写`javax.servlet.http.HttpServlet`,然后点击`Finish`。 2. 打开新创建的`HelloWorld.java`,重载`doGet`方法,添加以下代码: ```java import...

    JDBC初级入门及相关

    - 错误描述:“The superclass "javax.servlet.http.HttpServlet" was not found on the Java Build Path Login.jsp”。 - 解决方案:确认是否已经正确地将Tomcat服务器添加到了项目的Build Path中。 - 如果已经...

    浅谈导入JavaWeb 项目出现的问题

    Multiple annotations found at this line: - The superclass "javax.servlet.http.HttpServlet" was not found on the Java Build Path 这是一种常见的错误,主要是因为项目的 Java Build Path 中没有正确地添加 ...

    java异常解决方案.docx

    * java.lang.Error: Unresolved compilation problem: The method contextInitialized(ServletContextEvent) of type CreateDataSourceTableListener must override a superclass method + 解决方案:检查 Servlet ...

    JSP Simple Examples

    One of the strong features of java is that it is follows a OOPs concept, and one of the feature of OOP in java is that, we can assign a subclass object or variable to the variable of the superclass ...

    java.核心技术.第八版 卷1

    The following is the table of contents for the eighth edition, not yet shown on the product page at the time I am writing this: Chapter 1: An Introduction to Java 1 Java As a Programming Platform ...

    java面试题英文版及其答案

    12. Explain the concept of polymorphism in Java.Answer: Polymorphism is the ability of an object to take on many forms. In Java, it is achieved through method overriding and method overloading. Method...

    Java™ Puzzlers: Traps, Pitfalls, and Corner Cases.chm

    Java™ Puzzlers: Traps, Pitfalls, and Corner Cases.chm,英文版本,chm 格式,大小 1 Mb,作者:Joshua Bloch、Neal Gafter。 内容预览: Chapter 1. Introduction Chapter 2. Expressive Puzzlers Puzzle 1: ...

    The method of type must override a superclass method解决方式, myeclipse, java, web

    在Java编程语言中,"The method of type must override a superclass method" 是一个常见的错误提示,它通常出现在子类试图重写父类方法时,但没有按照正确的格式进行。这个错误通常与多态性和继承概念有关,是理解...

    Test_invoke_super_range.rar_Superclass

    在Java编程语言中,"super"关键字是用来引用当前对象的父类实例的。"Test_invoke_super_range.rar_Superclass"的标题暗示了我们讨论的是一个关于调用超类方法的主题,特别是与范围(range)有关的。这可能指的是在...

    《JAVA语言程序设计》期末考试复习资料.pdf

    根据提供的文件信息,我们可以总结以下JAVA语言程序设计的相关知识点: 1. Java类和对象的定义 在Java中定义一个类,需要使用关键字class。例如,class AB {...}定义了一个名为AB的类。对象是类的实例,例如在代码...

    java 扫雷 源代码

    FileOutputStream fos = new FileOutputStream(SuperClass.SaveGame_File); OutputStreamWriter osw = new OutputStreamWriter(fos); BufferedWriter Game_Writer = new BufferedWriter(osw); ``` 这里首先创建了一...

    Java Interview Guide.epub

    The Object Superclass? Composition & Inheritance? Abstract Classes & Interfaces? Exceptions? Generics? Concurrency? Memory Management? Java Database Connectivity? Web Applications? Web Services? ...

    JavaWeb仿小米在线商城ShoppingMall

    JavaWeb在线商城开发知识总结(java+jsp+servlet+MySQL+jdbc+css+js+jQuery) 可以实现浏览商品,查看商品详情,添加购物车,计算价格等功能 项目文章:...

    SSD7 选择题。Multiple-Choice

    (b) the name of the table, the names of the table's attributes, the data types of the table's attributes, the formats of the table's attributes, and the maximum number of rows that the table can have...

    Java 接口与继承

    Java中的继承和接口是面向对象编程的关键特性,它们在软件设计中扮演着至关重要的角色,实现了代码的重用和类的层次结构。 继承是Java中创建新类的一种方式,它允许一个子类(SubClass)从一个已存在的父类...

    Google C++ Style Guide(Google C++编程规范)高清PDF

    Do not depend on the symbol being brought in transitively via headers not directly included. One exception is if Foo is used in myfile.cc, it's ok to #include (or forward-declare) Foo in myfile.h, ...

Global site tag (gtag.js) - Google Analytics