This is my first java software...
The software works well on my dev machine, but I get that exception on the other (non-dev) machine (both on Windows 10) : java.lang.NoClassDefFoundError: org/jdom2/JDOMException
I read that there is something related with the JDOM versions, and that the key should be something with the xerces.jar order in the classpath (www.jdom.org)... I tried different approaches, without any result.
I work with NetBeans, and it is not clear for me how to include JDOM. What I did :
- Under
Tools
,Libraries
, I created a JDOM library, and included in itjdom-2.0.6.jar
, and also added thenxercesImpl.jar
, and alsoxml-apis.jar
, and checked that xerces comes first: JDOM library creation - Then, I use
Add Library...
by right-clicking on the Library folder of my project: Add Library
The software works well on my development PC... but then I this exception when creating my XML object, on another PC (which has no development environment) :
Exception in thread "AWT-EventQueue-0" java.lang.NoClassDefFoundError: org/jdom2/JDOMException
What am I doing wrong ?