I have a Spinner displaying some items via an Adapter. The thing is everytime I click on the spinnerm it shows the list of all items that are selectable by the user. I would like to hide the item currently selected from the list.
Example:
Here is my list of Items :
Selected: Item A
Spinner List:
- Item A
- Item B
- Item C
If I select Item B, it will become:
Selected: Item B
Spinner List:
- Item A
- Item B
- Item C
I would like to hide the selected item from the Spinner List. So, in the two previous cases:
Selected: Item A
Spinner List:
- Item B
- Item C
If I select Item B, it will become:
Selected: Item B
Spinner List:
- Item A
- Item C
You should create a list of seleted items. So everytime you select an item, you put on this list. After that you compare the two lists: the one with all values, with the one with the selected values and display only the items that aren't already selected. I've already used something like this:
I hope it helps