posted 22 years ago
Thanks a lot. I was afraid that I will have to do this. But finally I did that.
Now its working except few things.
Should I use firetableDataChanged() somewhere.
2) I had a scrollbar in the frame. Now that Scrolbar does not show up if the number of rows are more then the area defined.
This was initially where MyTableModel is the AbstractTableModel
MyTableModel myModel = new MyTableModel();
JTable table = new JTable(myModel);
table.setPreferredScrollableViewportSize(new Dimension(700,150));
JScrollPane scrol = new JScrollPane(table);
getContentPane().add(scrol,BorderLayout.CENTER);
After the values are changed I am using
new MyTableModel();
repaint();
Thanks.