I need to remove all items from the combo box
int itemCount = combo.getItemCount(); for(int i=0;i
In second line:
combo.removeItemAt(0);
combo.removeItemAt(0)
I think instead of 0 it should be i.
0
i
do it in reverse order as:
for(int i=combo.getItemCount()-1;i>=0;i--){ combo.removeItemAt(i); }
But in my case combo.removeAllItems() works fine
combo.removeAllItems()