Forums Register Login

How to stop editting the Cell

+Pie Number of slices to send: Send
Hi all

i Have a JTable with the Custom Renderer and Editor
The Editor has the Button which on click open the dialog and select some data(data is updating in the model no issue)

Issue i am facing
1. I want to stop editting after cilcking the OK button in the Dailog.
2. The Data will effect which i resize the coloumn, How can i do that automatically.

Please help on this.
+Pie Number of slices to send: Send
1) You need to invoke the stopCellEditing() method of the editor.

2) If I understand the question then you can use the TableColumnAdjuster.
+Pie Number of slices to send: Send
Thank you Rob

The issue was i have to call fireEdittingStopped(); in th Editor after closing the dialog

Its working fine now, Thanks for your support.
No matter. Try again. Fail again. Fail better. This time, do it with this tiny ad:
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com


reply
reply
This thread has been viewed 824 times.
Similar Threads
Issue with JTables and saving on screen content to underlying TableModel
JTable
Re-assigning values to variables
No editting to the JTable
Problem in JTable Renderer and Editor
More...

All times above are in ranch (not your local) time.
The current ranch time is
Mar 28, 2024 13:21:48.