I am trying to add JComponents to JTable Cells. Do I Implement CellRenderer or CellEditor?
What you need is a custom editor which will return the JComboBox (or whatever component you want to use). You should check the Sun tutorial for JTable, it contains an example on how to use a JComboBox as an editor. If you want to use JComboBox as a renderer as well, the tutorial applies to that too.
1.4m articles
1.4m replys
5 comments
57.0k users