Meaningless Drivel is fun!
The moose likes Swing / AWT / SWT and the fly likes JComboBox in the JTable Editor Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Swing / AWT / SWT
Bookmark "JComboBox in the JTable Editor" Watch "JComboBox in the JTable Editor" New topic

JComboBox in the JTable Editor

Chiranjeevi Kanthraj
Ranch Hand

Joined: Feb 18, 2008
Posts: 290

Hi All

I have a JTable which is having the JComboBox as a Cell Editor.
Where JTable has the Selection Listner, Where i can select single row.

Problem is when i try to select the row, by clicking on the JComboBox cell, the both ComboBox DropDown and the Table Row selection listner will trigger.
So the Drop down will go off.. and selection will happen.

so i need to click twice to see the JCombobox dropdown menu.

Please help me how i can handle this.

Thanks in advance

Ranganathan Kaliyur Mannar

Joined: Oct 16, 2003
Posts: 1101

You need to make use of the method setClickCountToStart(). This has been discussed most recently here

I agree. Here's the link:
subject: JComboBox in the JTable Editor
It's not a secret anymore!