facebook

the import org.apache.log4j can not be resolved

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

    pallavi1974
    Member

    Hi,
    I got problems like
    the import org.apache.log4j can not be resolved;
    Logger can not be resolved.
    can somebody know why these errors are coming??
    Thanks

    #222047 Reply

    Scott Anderson
    Participant

    Can you please post all the information we request in the [URL=http://www.myeclipseide.com/PNphpBB2+file-viewtopic-t-393.html]Posting Guidelines[/URL] thread at the top of this forum? That will give us some context so that we can determine if this is an installation issue, a configuration problem, or a bug. Thanks.

    #222112 Reply

    pallavi1974
    Member

    Hi Scott,
    What operating system and version are you running?
    Windows XP SP1
    What Eclipse version and build id are you using? (Help > About Eclipse Platform)
    eclipse 3.0.1
    build 200409161125
    – Was Eclipse freshly installed for MyEclipse?
    yes
    – If not, was it upgraded to its current version using the update manager?
    – Are any other external plugins installed?
    no
    – How many plugins in the <eclipse>/plugins directory are like org.eclipse.pde.*
    8
    What MyEclipse version are you using? (Help > About Eclipse Platform > Features)
    3.8.3
    What JDK version are you using to run Eclipse? (java -version)
    jdk1.4.2_03
    What JDK version are you using to launch your application server?
    jdk1.4.2_03
    What steps did you take that resulted in the issue?
    I have code that is using log4j.i imported that file in to eclipse.I got this “the import
    org.apache.log4j can not be resolved,Logger can not be resolved.”
    What application server are you using?
    weblogic 8.1 SP2
    Are there any exceptions in the Eclipse log file? (<workspace>/.metadata/.log)
    no exceptions in .log file
    Thanks
    PALLAVI

    #222115 Reply

    Scott Anderson
    Participant

    Pallavi,

    I have code that is using log4j.i imported that file in to eclipse.I got this “the import
    org.apache.log4j can not be resolved,Logger can not be resolved.”

    Did you import the log4j jar file into your project? Did you add it to the classpath? What type of project are you using?

    #222116 Reply

    pallavi1974
    Member

    I am using java project. log4j.jar file is in the lib directory of my project.
    Can u please tell me how to add it to classpath??
    Thanks

    #222119 Reply

    Scott Anderson
    Participant

    Right click on the project in the Package Explorer View and select Properties > Java Build Path > Libraries > Add Jar… and select the jar file in your project.

    #222122 Reply

    pallavi1974
    Member

    Thank you very much.I got it.

    #222123 Reply

    Scott Anderson
    Participant

    No problem. But I would suggest you read the Java Developers Guide in the Eclipse Help System at Help > Help Contents, just to get the basics down. Eclipse has a big learning curve and the docs do help to get you over the hump pretty well. 🙂

    #257256 Reply

    maximuszen
    Member

    I’ve been using eclipse for a while and I’m getting this error. When I click Add jar there is no items in the list. Do you mean add external jar? When I do there is a duplicate copy of the log4j in my deployment this creates errors on its own.

    #307032 Reply

    kalyan.jitta
    Member

    hi,

    iam adding my properjavardp appl in eclipse and i compiled,but i got a this msg the import org.apache.log4j can not be resolved, so plse give solution very soon

    #307033 Reply

    kalyan.jitta
    Member

    plse send me solution very soon,because i work on that project[quote]

    #307093 Reply

    Kalyan,
    Your issue is not clear, can you give some more information?
    1. Can you copy paste your installation details from MyEclipse > Installation Summary > Installation Details?
    2. Have you added the jar file to your projects build path(Right click on your project, select Build Path > Add External Archives from the context menu)?

    #307102 Reply

    kalyan.jitta
    Member

    hi,
    give me the procedure of executing exist porperjava rdp in eclipse by using applets

    #315249 Reply

    chevizflex
    Member

    Hello,
    What operating system and version are you running?
    Windows XP SP2
    What Eclipse version and build id are you using? (Help > About Eclipse Platform)
    myeclipse 7.5
    build 20090609
    – Was Eclipse freshly installed for MyEclipse?
    no
    – If not, was it upgraded to its current version using the update manager?
    – Are any other external plugins installed?
    flex builder 3 plug-in
    – How many plugins in the <eclipse>/plugins directory are like org.eclipse.pde.*
    4
    What MyEclipse version are you using? (Help > About Eclipse Platform > Features)
    7.5
    What JDK version are you using to run Eclipse? (java -version)
    jdk1.5
    What JDK version are you using to launch your application server?
    jdk1.5
    What steps did you take that resulted in the issue?
    I have code that is using log4j.i imported that file in to eclipse.I got this “the import
    org.apache.log4j can not be resolved,Logger can not be resolved.”
    What application server are you using?
    JBoss v4.2
    Are there any exceptions in the Eclipse log file? (<workspace>/.metadata/.log)
    no exceptions in .log file

    i want to know, how to install .jar files & log4j in myeclispse and how to set the build path when we use Adobe Flex Plug-in.

    Thanks
    Chevi

    #315269 Reply

    support-swapna
    Moderator

    chevizflex,

    1) If working in a Web project you can add the jars to the lib directory and they should
    automatically be found. You can also add the jars to your project’s path
    by changing the project build properties. Right click on your project and
    select properties.

    2) Here is a thread which discusses about log4j. Have a look at it :
    http://www.myeclipseide.com/PNphpBB2-viewtopic-t-26938-highlight-log4j.html

    3) How are you trying to install Flex plugin? Is it through the update site ? Once the plugin is installed into MyEclipse you should be able to use it without making any changes to the build path. Also make sure that the version of Flex 3 plugin is compatible with the base version of Eclipse 3.4.

Viewing 15 posts - 1 through 15 (of 15 total)
Reply To: the import org.apache.log4j can not be resolved

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