James Peter wrote:When I enter the value in table cell and without pressing Enter Key if I click print button I found that content of a cell which is having focus at present is not getting retrieved.
Call
where
table is the variable referring to your JTable. That will cause the cell editing to stop (terminate) whenever the JTable loses focus, like when a button is pressed.
I also noticed that tableChanged method is not being called while wevkey in values in cell.
That's because the table cell editor hasn't committed its current value to the JTable yet. It won't until you press Enter, or until you "flush" the data to the TableModel manually (using setValueAt).