Bonjour,

J'ai crée un Container qui contient des chekbox et cela avec cette méthode :

Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
public static Container getCheckbox(String str[], int size) {
        Container checkBox = new Container(new BoxLayout(BoxLayout.Y_AXIS));
        checkBox.addComponent(new Label("Operations "));
        for (int i = 0; i <= size; i++) {
            CheckBox op = new CheckBox(str[i]);
            op.getStyle().setMargin(Component.TOP, 1);
            checkBox.addComponent(op);
        }
        return checkBox;
    }
j'ai besoin d'une méthode pour connaitre le numéro de chekbox sélectionner.

Merci d'avance