Re: JTable creation in swing
Hi Venkat,
To add data to a table dynamically, you will have to extend javax.swing.table.AbstractTableModel. In this class there is a method called getValueAt(rowIndex, colIndex). This method is a call back method that is called whenever the table is repainted. So you will have to implement this method to return the values. The parameters passed are the rowIndex and the colIndex.
Hope this helps. Consult the Java API's for description of the other methods present in the AbstractTableModel.
Regards,
Sahil.
[SIZE=1][COLOR=Gray]
--Win as if you were used to it,
loose like you enjoyed it for a change!!![/COLOR][/SIZE]