Hello,
I'm using a JTable (using a DefaultTableModel) and I want to do
something whenever a different row is selected in a JTable. The closest
I've got is doing the same for columns, by attaching a
TableColumnModelListener to the column model of my table. But I can't
see any similar row listener.
Any ideas?
Thanks

Signature
Nick Howes
Thomas Fritsch - 04 Feb 2004 15:46 GMT
> Hello,
> I'm using a JTable (using a DefaultTableModel) and I want to do
[quoted text clipped - 5 lines]
> Any ideas?
> Thanks
table.getSelectionModel().addListSelectionListener(new ListSelectionListener()
{
public void valueChanged(ListSelectionEvent e)
{
// do what you want ...
}
});
______________________________________________________
Thomas <dot> Fritsch <at> ops <dot> de
Nick H - 05 Feb 2004 17:14 GMT
>> Hello,
>> I'm using a JTable (using a DefaultTableModel) and I want to do
[quoted text clipped - 8 lines]
> }
> });
bingo