• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
  • Mikalai Zaikin

Problem with editable combo box!Pls Help me

Ranch Hand
Posts: 40
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Folks,
I have a problem with the combo box in a JDialog window. The problem is as follows...
1) I have a combo box which is editable followed by 3 text boxes and ok/cancel/apply buttons in it.
2) Whenever an user edits the combo box and after that whatever be the clickevent say clicking ok/apply/cancel or clicking any text boxes within the dialog box, combo box automatically fires an event. So the code in the actionPerformed(or ItemStateChanged) part of the JComboBox gets executed Instead of the actionPerformed part of the ok/apply/cancel buttons..Only in the next click the corresponding code of the button gets executed...In brief..the JComboBox automatically fires an event...
How to overcome this?.I have copied my code below.
Don't get me started about those stupid light bulbs.
    Bookmark Topic Watch Topic
  • New Topic