1

Possible Duplicate:
How do I make a list with checkboxes in Java Swing?

I want to display some items in a list which are checkable . User can Select/Deselect an item in the list . Or in otherwards

and if the item in the list is double clicked then there will be some command

can anyone help me with this

Community
  • 1
  • 1
Carlo
  • 1,147
  • 3
  • 15
  • 23

1 Answers1

2

Use a JTable with two columns:

  • an editable boolean one for the checkbox
  • a non-editable one for the text

Read the Swing tutorial about tables.

JB Nizet
  • 678,734
  • 91
  • 1,224
  • 1,255