After creating the grill with “GridLayout”:
supper(new GridLayout(rows, column));
I will add to demand content in each cell:
public void addButton(String name) {
buttons = new JButton(name);
add(buttons);
}
As I can I know the current number of cells used to keep a counter of addition and deletion?.
Thanks.
You could check with
Container.getComponentCount().