On Thu, 20 Sep 2007 03:51:27 -0700, Chanchal
<chanchal.jacob@gmail.com> wrote, quoted or indirectly quoted someone
who said :
> Is ther anyway cells can be merged row-wise in JTable? Any sample
>code available?
What do you mean by merged?
Do you mean for example to add two rows together, putting the result
in the first row, then delete the second?
If so, just do the merge in your model is a the ordinary way, then
fire the appropriate change events to notify JTable to repaint.
TableModel is the part you write to manage the data. When data change,
the TableModel fires events to let the GUI know to refresh portions of
the table. You do this with AbstractTableModel.fireTableCellUpdated,
fireTableRowsUpdated, fireTableRowsDeleted, fireTableDataChanged or
fireTableStructureChanged. Use the most specific method, e.g.
fireTableCellUpdated in preference to fireTableRowsUpdated if you just
updated a few cells. Data are organised in rows and columns. Cells can
contain nulls which will paint happily as blank.
For more detail see http://mindprod.com/jgloss/jtable.html

Signature
Roedy Green Canadian Mind Products
The Java Glossary
http://mindprod.com