Twitter iPhone pliant OnePlus 11 PS5 Disney+ Orange Livebox Windows 11

AWT ? SWING ? une erreur suspecte

1 réponse
Avatar
Goddy
[18:55]-[god@GodMac]/Volumes/Donnee/travail/prog/edp$ java Main
Exception in thread "AWT-EventQueue-0" java.lang.NoClassDefFoundError:
org/jdom/Content
at Main$1.run(Main.java:20)
at
java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:209)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:461)
at
java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchThread.j=
ava:269)
at
java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.jav=
a:190)
at
java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:184)
at
java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:176)
at
java.awt.EventDispatchThread.run(EventDispatchThread.java:110)



le Main :

SwingUtilities.invokeLater(new Runnable(){
public void run(){
Edp doc =3D new Edp(); // LIGNE 20
//On cr=E9e une nouvelle instance de notre fen=EAtre
Ihm fenetre =3D new Ihm(doc);
fenetre.setVisible(true);//On la rend visible
}
});




Constructeur de Edp :

public Edp(){
fichier =3D new String("edp.xml");
charger();
}


la compilation passe sans probl=E8me et =E0 l'execution j'ai l'erreur
ci-dessu

Sachant qu'=E0 l'execution sous eclipse le programme fonctionne , ici je
le lance en ligne de commande

Qq1 aurai une id=E9e sur cette erreur ?


(java 1.5, macosx )

1 réponse

Avatar
anotherboo
bonjour;

ni awt ni swing ne sont responsable de cette erreur.
c est lapi jdom qui nest pas trouvée.
veriie dans ton classpath l existence de cette api.
y.


Goddy wrote:
[18:55]-[]/Volumes/Donnee/travail/prog/edp$ java Main
Exception in thread "AWT-EventQueue-0" java.lang.NoClassDefFoundError:
org/jdom/Content
at Main$1.run(Main.java:20)
at
java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:209)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:461)
at
java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchThread .java:269)
at
java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.j ava:190)
at
java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:184)
at
java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:176)
at
java.awt.EventDispatchThread.run(EventDispatchThread.java:110)



le Main :

SwingUtilities.invokeLater(new Runnable(){
public void run(){
Edp doc = new Edp(); // LIGNE 20
//On crée une nouvelle instance de notre fenêtre
Ihm fenetre = new Ihm(doc);
fenetre.setVisible(true);//On la rend visible
}
});




Constructeur de Edp :

public Edp(){
fichier = new String("edp.xml");
charger();
}


la compilation passe sans problème et à l'execution j'ai l'erreur
ci-dessu

Sachant qu'à l'execution sous eclipse le programme fonctionne , ici je
le lance en ligne de commande

Qq1 aurai une idée sur cette erreur ?


(java 1.5, macosx )