Change JTable on a JPanel
843804Oct 27 2004 — edited Oct 27 2004Hi, I doing a program and I found a little thing that is driving me crazy!
I have a JPanel that have a JTable inside a JScrollPane. Nothing new here. There is various buttons on the window and one of the buttons constructs a new table with data from a database that I want to substitute in the JScrollPane.
How can I do this? The only way I found is to remove all lines from the table and add one by one again.
If I change the JTable variable with a the new one, isn't there a way to redraw the JFrame with the new table ?
Thanks in advance to everyone that helps this beginner!
Eduardo