Eclipse Error: "org.apache cannot be resolved"

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Alien
    New Member
    • Sep 2007
    • 61

    #1

    Eclipse Error: "org.apache cannot be resolved"

    Hi guys,

    I am doing JSP stuff in eclipse and when I open my file, i get a red cross on the line:

    [code=java]
    <%@page import="org.apa che.xml.seriali ze.*"%>
    [/code]

    When i move my mouse over it says:

    Multiple annotations found at this line:
    - The import org.apache cannot be
    resolved
    - The import org.apache cannot be
    resolved


    It seem it cant find the classes needed.

    Also if i scroll down my code, eclipse give red underline on all classes coming in from that org.apache.xml. serialise like "OutputForm at" and "XmlSeriali zer" etc.Its a big code which is why I didn't paste it but code is fine, its with import statement and eclipse being unable to link with the needed libraries.


    I downloaded Xerces, extracted the Jar files and put them in my WEB-INF directory so the classes needed are in /WEB-INF/org/apache/xml/Serialise

    That didnt work. Any suggestions anyone? Thanks heaps for looking at it. I attached screenshot of my Eclipse below
    Attached Files
  • r035198x
    MVP
    • Sep 2006
    • 13225

    #2
    Don't extract the class files. Just add the jar file to your class path.
    You should also not be writing Java code inside JSPs anyway.

    Comment

    Working...