I am having the following issue: I have a JTable with its on tablemodel sitting on a JFrame. The tablemodel is backed up with an own hashmap to store the contents. The table has two columns where the right one is editable.
Normally the user changes some value on the right then presses the enter button which fires the tabledatachanged event that calls my saving function. Then the frame can be closed.
However, some users just simply edit the cell and then they close the window without pressing enter so I get no chance to save the table. I know how to write events when the frame is about to be closed, but I do not know how to retrieve the content of the "unfinished" editing while also finalizing that edit.
I guess it has something to do with the celleditors, I even tried with the table.getCellEditor() that should return the active one but instead it returns null.
Thanks for the help!