omcougar
Messages postés152Date d'inscriptionmardi 4 mai 2004StatutMembreDernière intervention 8 octobre 2008
-
5 sept. 2006 à 13:11
super_toinou
Messages postés764Date d'inscriptionmardi 25 mai 2004StatutMembreDernière intervention 8 mars 2011
-
5 sept. 2006 à 16:23
Bonjour,
quand je lance mon appl j'ai un message d'erreur qui apparait sans pour autant faire planter quoi que ce soit... comme fait on pour degugguer un truc sur lequel on a aucune info ? (Unknown Source)
Exception in thread "AWT-EventQueue-0"
java.lang.NullPointerException
at javax.swing.plaf.basic.BasicTableUI.paintCells(Unknown Source)
at javax.swing.plaf.basic.BasicTableUI.paint(Unknown Source)
at javax.swing.plaf.ComponentUI.update(Unknown Source)
at javax.swing.JComponent.paintComponent(Unknown Source)
at javax.swing.JComponent.paint(Unknown Source)
at javax.swing.JComponent.paintWithOffscreenBuffer(Unknown Source)
at javax.swing.JComponent.paintDoubleBuffered(Unknown Source)
at javax.swing.JComponent._paintImmediately(Unknown Source)
at javax.swing.JComponent.paintImmediately(Unknown Source)
at javax.swing.RepaintManager.paintDirtyRegions(Unknown Source)
at javax.swing.SystemEventQueueUtilities$ComponentWorkRequest.run(Unknown Source)
at java.awt.event.InvocationEvent.dispatch(Unknown Source)
at java.awt.EventQueue.dispatchEvent(Unknown Source)
at java.awt.EventDispatchThread.pumpOneEventForHierarchy(Unknown Source)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.run(Unknown Source)
super_toinou
Messages postés764Date d'inscriptionmardi 25 mai 2004StatutMembreDernière intervention 8 mars 20116 5 sept. 2006 à 16:23
tu prend JBuilder (je sais pas si Eclipse le fait mais je pense)
t ajoute un point de type point d arret exception
la dessus tu spécifie le type d exception sur lequel il doit s arreter
dans ton cas nullpointer
et quand l execution du pg arrivera a l exception tu en sera notifié, tu pourra voir la valeur dess variables a ce moment la, voir la stack d appel et revenir en arrière pour voir ce que t as mal fait !!
++ Toinou
thevman
Messages postés83Date d'inscriptionlundi 5 septembre 2005StatutMembreDernière intervention 3 juillet 2008 5 sept. 2006 à 14:12
Tu as essayé de localiser la zone de code qui déclanche cette erreur?
Par example avec des points d'arret :
Tu commences par en mettre à la fin de chaque appel de tes classes.
Puis des que tu chopes l'erreur tu descends avec un niveau plus fin à chaque fois (dans chaque méthode , etc) .
tu peux proceder de la meme maniere avec des try catch et tu changes le message d'erreur afin de choper la zone de code défaillante.
Je pense que tu as du essayer mais c'est la seul facon de localiser ces cochoneries de nullpointer.