Je voudrais insérer un JCheckBox dans ma JTable mais cela m'affiche dans ma cellule "java.swing...".


voici mon code java

Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
 
public class ListBox extends JPanel{
 
   JTable table;
 
 
            public ListBox(){
	    JCheckBox[][]liste= {
		{new JCheckBox("tres bien")},
		{new JCheckBox("bien")},
		{new JCheckBox("moyen")},
		{new JCheckBox("nulle")}
	      };
 
	      String[] titreColonnes= {"apreciation"};
 
	     JTable jTable1 = new JTable(liste, titreColonnes);
	      add(jTable1);
	}
 
 
	public static void main(String args[]){
	     JFrame f=new JFrame();
	     ListBox box=new ListBox();
	     f.add(box);
	     f.setSize(100, 100);
	     f.setVisible(true);
	}
 
}

Pourriez vous m'aider SVP