java.lang.ClassCastException: java.lang.String

Oracle Community | 807553 | 1 decade ago
tip
Click on the to mark the solution that helps you, Samebug will learn from it.
As a community member, you’ll be rewarded for you help.
  1. 0

    help on customized TableModel please !!!!!!

    Oracle Community | 1 decade ago | 807553
    java.lang.ClassCastException: java.lang.String

    Root Cause Analysis

    1. java.lang.ClassCastException

      java.lang.String

      at monitor.CustomTableModel.getValueAt()
    2. monitor
      CustomTableModel.getValueAt
      1. monitor.CustomTableModel.getValueAt(TimeTable.java:154)
      1 frame
    3. Java RT
      EventDispatchThread.run
      1. javax.swing.JTable.getValueAt(JTable.java:1714)
      2. javax.swing.JTable.prepareRenderer(JTable.java:3533)
      3. javax.swing.plaf.basic.BasicTableUI.paintCell(BasicTableUI.java:995)
      4. javax.swing.plaf.basic.BasicTableUI.paintCells(BasicTableUI.java:917)
      5. javax.swing.plaf.basic.BasicTableUI.paint(BasicTableUI.java:858)
      6. javax.swing.plaf.ComponentUI.update(ComponentUI.java:39)
      7. javax.swing.JComponent.paintComponent(JComponent.java:395)
      8. javax.swing.JComponent.paint(JComponent.java:687)
      9. javax.swing.JComponent.paintChildren(JComponent.java:498)
      10. javax.swing.JComponent.paint(JComponent.java:696)
      11. javax.swing.JViewport.paint(JViewport.java:668)
      12. javax.swing.JComponent.paintChildren(JComponent.java:498)
      13. javax.swing.JComponent.paint(JComponent.java:696)
      14. javax.swing.JComponent.paintChildren(JComponent.java:498)
      15. javax.swing.JComponent.paint(JComponent.java:696)
      16. javax.swing.JComponent.paintWithBuffer(JComponent.java:3878)
      17. javax.swing.JComponent._paintImmediately(JComponent.java:3821)
      18. javax.swing.JComponent.paintImmediately(JComponent.java:3672)
      19. javax.swing.RepaintManager.paintDirtyRegions(RepaintManager.java:370)
      20. javax.swing.SystemEventQueueUtilities$ComponentWorkRequest.run(SystemEventQueueUtilities.java:124)
      21. java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:154)
      22. java.awt.EventQueue.dispatchEvent(EventQueue.java:337)
      23. java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchThread.java:131)
      24. java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:98)
      25. java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:93)
      26. java.awt.EventDispatchThread.run(EventDispatchThread.java:85)
      26 frames