amp834
asked on
Java JTable clicking out of a field that is being edited does not update field values
I display a JTable with editable text columns, when the user double-clicks on a column to edit a field, then clicks on another column, the field that was edited gets updated. But if the user double-clicks on a column to edit the field, makes changes, then presses a JButton somewhere on the same form, the table value is not updated automatically. (The JButton code uses the values in the table, and is not getting the latest value from that last field that was being edited.)
Is there a way to make JTable automatically update a field that's being edited when the focus changes to something else? Or at least is there some call I can put in the JButton's code to say "Finish/update and edits that were being done on the JTable"?
Is there a way to make JTable automatically update a field that's being edited when the focus changes to something else? Or at least is there some call I can put in the JButton's code to say "Finish/update and edits that were being done on the JTable"?
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER