Selections in a JTable combined with fireTableRowsUpdated(...)

From: Klaus Jacobsen (none_at_here.dk)
Date: 10/28/03


Date: Tue, 28 Oct 2003 09:06:02 +0100

Hi!

I have a JTable with a custom AbstractTableModel. when data changes in the
model i call fireTableRowsUpdated(...), but when I do this selections in the
table are cleared/removed.

What can i do to prevent selected rows from being deselected upon calling
fireTab....?
Is the answer: ListSelectionListener and keeping track of selections myself?
There must be an easier way!

Regards Klaus Jacobsen



Relevant Pages

  • clean up selection optinons in pivot tables
    ... data changes the possible selections in the pivottable do not change, ... I have 100 customers in my pivottable, I update my data that has only 5 ... In the updated pivot table I can still select from ...
    (microsoft.public.excel.programming)
  • JList Font Bug
    ... // allowing multiple selections, the default. ... flavour.addListSelectionListener(new ListSelectionListener() ... value of the selection changes. ...
    (comp.lang.java.gui)