• Post Reply Bookmark Topic Watch Topic
  • New Topic

Editing table  RSS feed

 
Antony Amicone
Ranch Hand
Posts: 125
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I want to make my jtable editable, for every edit on a cell, i want to get a joptionpane to confirm the editing.
after that i retrieve edited data with .getValueAt and i send a query UPDATE to my db and finally a firetablechanged

is it correct? if it is, how to set my jtable editable?
 
Jeanne Boyarsky
author & internet detective
Sheriff
Posts: 37256
519
Eclipse IDE Java VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
This seems like move of a GUI question. Moving to our Swing forum.
 
Rob Spoor
Sheriff
Posts: 21095
85
Chrome Eclipse IDE Java Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I think the easiest way is to override setValueAt:
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!