Bonjour,
J'ai créé une table ayant des items, parmi ces items il y en a qu'on peut sélectionner et d'autres non.
Comment rendre un TableItem disabled (comme pour un composant avec Control.setEnabled(false))?
Merci d'avance,
Version imprimable
Bonjour,
J'ai créé une table ayant des items, parmi ces items il y en a qu'on peut sélectionner et d'autres non.
Comment rendre un TableItem disabled (comme pour un composant avec Control.setEnabled(false))?
Merci d'avance,
Salut,
Je crois que ton bonheur se trouve à cette adresse, je pense que ça se rapproche de très prêt de ce que tu recherches !
http://tom-eclipse-dev.blogspot.com/...tree-with.html
Bonjour,
J'ai une table de type swt
Je n'ai pas pu disabled un item d'index i.Code:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15 table = new Table(this.composite, SWT.HIDE_SELECTION|SWT.SINGLE|SWT.FULL_SELECTION|SWT.BORDER|SWT.V_SCROLL); for (int i = 0; i< 10 ; i++) { String int_value = String.valueOf(ran.nextInt(1000000)); String string_value = "50"; String date_value = "" + ran.nextInt(31) + "/" + ran.nextInt(12) + "/" + ran.nextInt(2000); // dd-mm-aaaa String double_value = String.valueOf(ran.nextDouble()); String hour_value = "" + ran.nextInt(24) + ":" + ran.nextInt(60) + ":" + ran.nextInt(60); // hh:mm:SS // ok now store it in the table TableItem item = new TableItem(table, SWT.NONE); item.setText(new String[] { int_value, string_value, date_value, double_value, hour_value }); }