Hello I have a column in a JTable that needs to display values in a JComboBox. My problem is that the contents of the comboBox are different for each row of the JTable. Can someone direct me on how to program this ? Thanks in advance Jean Richard
Thomas Suer
Ranch Hand
Joined: Sep 03, 2001
Posts: 50
posted
0
It would be the same way as filling the table's cells with individual values. In your case I would write a table model that returns for this column a set of the appropriate possible values (e.g. an array of values or a self written data class that encapsulates the values) and a table cell renderer for this column that returns a combobox with the appropriate content. Tom