facebook

Multiple Markers at this line [Closed]

  1. MyEclipse IDE
  2.  > 
  3. General Development
Viewing 10 posts - 1 through 10 (of 10 total)
  • Author
    Posts
  • #218645 Reply

    Hi,
    I am working on a web project to deploy on tomcat server. I have several JSP files and a few servlets and some class files (used as beans). In one of my class files on the first line I have this red error marker. When I moved my mouse on it it displays the following:

    Multiple markers at this line
    – The type java.lang.object cannot be resolved. It is indirectly referenced from the required .class files
    – 82 changed lines

    What does this mean? I can’t find any help about this error anywhere. I searched on this website and on google. Nothing found. By the way when I deployed my war files, the class files were not created and deployed. Please let me know how to fix this. My deadline is fast approaching.

    Thanks in advance.

    Chandra

    #218646 Reply

    Riyad Kalla
    Member

    Chandra,
    This sounds like a straight Eclipse error. What does your classpath look like? Right click on your Project root > Properties > Java Build Path > Libraries, tell me what is listed.

    #218654 Reply

    Riyad,
    Thanks for quick response. There are two entries there: commons-fileupload-1.0.jar and J3EE 1.4 Library Container. The library container had a bunch of jars under it from activation.jar to xml-apis.jar.

    Am I missing something?

    Chandra.

    #218656 Reply

    Riyad Kalla
    Member

    Ahh yea you are missing your JRE System Library (your main JDK classes), hit “Add Library” and then “J2SE System Library” and hit OK, then rebuild app (it will prompt you).

    #218666 Reply

    Riyad,
    Thanks. I just figured that out. I had accidentally removed it earlier. However there is another problem. I am using mail API in my servlet to send email. When I deploy my app to Tomcat and try the servlet. I get the error “java.lang.NoClassDefFoundError: javax/mail/Address”. Looks like I need to deploy mail.jar and activation.jar along with my application. Where in myEclipse do I specify that?

    Chandra.

    #218674 Reply

    Riyad Kalla
    Member

    Chandra,
    As with any web application (and MyEclipse) those libraries will need to into your WebRoot/WEB-INF/lib directory.

    #234492 Reply

    maxwildcat
    Member

    i’m sorry, i’m having the same problem but i’m not sure i understand the reply (about the library) could you elaborate on how to add the userlibrary and how to find it (if it on my hdd)

    #234493 Reply

    Riyad Kalla
    Member

    Max,
    All libraries are added to your project build path via youir project properties then clicking Java Build Path and then the Libraries tab.

    If you don’t know where this file is, you can safely download JavaMail API from Sun’s site, it’s a free framework you can use. When you get the activation and javamail JARs ready, drop them into your WEB-INF/lib dir, MyEclipse will automatically mount them into your build path for you.

    #257815 Reply

    anindya_y2k
    Member

    i have mapped my project in eclipse 3.2.but i am getting the similar error. but the multiple markers error is not at a .class file.
    i have written some code where i have used enumeration. the error says

    “Multiple Markers at this line” Syntax error on token “enum” ++ expected–Enumeration cannot be resolved

    whereas in the code i have imported java.util.enumeration successfully.
    interestingly the line “java.util.enumeration” dont throw any error but where i am making an object

    Enumeration enum;

    it throws the above error

    i have placed all the jars which are required by my project and i dont have any other error except this error.
    in addition JRE System Library is also at the Java Build Path along with the jars which are dependent on project

    it will be great if you suggest something

    ———————————
    Anindya Chakraborty
    JP Morgan Chase
    Corporate Internate group

    #257832 Reply

    Riyad Kalla
    Member

    Anindya,
    Are you working on a Java 1.4 project or 1.5? I’m curious if you need the Enumeration class or the enum type. Also is it a mistype that you imported java.util.enumeration (lowecase E) or did you really type that import in, in which case it needs to be an upper case E.

Viewing 10 posts - 1 through 10 (of 10 total)
Reply To: Multiple Markers at this line [Closed]

You must be logged in to post in the forum log in