Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie

Eclipse add library problem

Options
  • 26-02-2007 2:24pm
    #1
    Closed Accounts Posts: 17,208 ✭✭✭✭


    Hey guys,

    I'm having a bit of trouble adding a library to my project.

    I have created a sub folder lib in my project folder, and put the JAR file into that (nanoxml-lite-2.2.3.jar). I then added the JAR to the build path in the Libraries tab of the Build Path editor.

    Now this all works fine when I'm in Eclipse. I can navigate through the JAR under the Package Explorer, and I can reference the files while editing code. The problem comes when I launch the application.

    I'm writing a MIDlet, emulating it with the Motorola EclipseME-supplied plugin emulator. I get no errors when the app is building, but when I am running it and it gets as far as that classes call it throws out ALERT: Unable to load class nanoxml/XMLElement and shuts down.

    I'm using Eclipse 3.2.1, Java 6, WTK 2.2, Motorola SDK 6.3 for Motorola OS Products and its bundled EclipseME 1.5.0 plugin.

    Anyone have any ideas?


Comments

  • Registered Users Posts: 23 saml1


    try adding it to the Runtime classpath for the plugin (runtime tab in the manifest), had a similar problem and that fixed it for me


  • Closed Accounts Posts: 17,208 ✭✭✭✭aidan_walsh


    I'm not sure I understand what you mean by that...


  • Registered Users Posts: 23 saml1


    is it a plugin you are developing?
    if so, add it to the classpath in your manifest.mf under Runtime tab
    if not
    go to your Run properties and add the jar to the classpath

    (ie. you need the library at runtime in your classpath)
    See Eclipse help: Creating a Java application launch configuration


  • Closed Accounts Posts: 17,208 ✭✭✭✭aidan_walsh


    Its not a plugin.
    I'm writing a MIDlet, emulating it with the Motorola EclipseME-supplied plugin emulator.


  • Closed Accounts Posts: 17,208 ✭✭✭✭aidan_walsh


    For whats its worth, I've checked inside the MIDlet JAR and the JAR file is being included. Still getting the error though.


  • Advertisement
Advertisement