wood burning stoves 2.0*
The moose likes Swing / AWT / SWT and the fly likes event handling in jtable Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » Swing / AWT / SWT
Bookmark "event handling in jtable" Watch "event handling in jtable" New topic
Author

event handling in jtable

Rajesh em
Greenhorn

Joined: Nov 01, 2004
Posts: 1
Hai
i am new to this ,
how to handle events if more than one combo box used in jtable
e.g..
if u click on the first combo get the selected name or combo according to that the values should be added on the next combo..

pl.reply soon
Craig Wood
Ranch Hand

Joined: Jan 14, 2004
Posts: 1535
Add a ListSelectionListener to the table SelectionModel and to the TableColumnModel SelectionModel of each TableColumn. Find the selected cell(row,col) in the valueChanged method and determine what you want to do with the selected value based on the (row,col) position.
 
wood burning stoves
 
subject: event handling in jtable
 
Similar Threads
JComboBox in a JTable
JTable
JTable
Jtable combo box issue
JTable not showing combobox dropdown arrow