This week's book giveaway is in the JavaScript forum.
We're giving away four copies of Cross-Platform Desktop Applications: Using Node, Electron, and NW.js and have Paul Jensen on-line!
See this thread for details.
Win a copy of Cross-Platform Desktop Applications: Using Node, Electron, and NW.js this week in the JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

JCheckBox  RSS feed

 
Le Wang
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi, I use JCheckBox in my project, I selected several boxes, then deselected some of them, who knows how to get the deselected Items?
Thanks in advance!

 
Jennifer Garrett
Greenhorn
Posts: 13
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Maybe you should try adding an Item Listener and whenever something is selected or deselected you can do whatever. There's an example in the java tutorial:
http://java.sun.com/docs/books/tutorial/uiswing/components/button.html#checkbox
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!