Hello, i am tryng to figuring out how to remove a specific index from several spinners at once.
My app have 10 spinner, every spinner have values from 1 to 10:
spinner1 = 1>10
spinner2 = 1>10 and so on.
All the spinners share the same event and i load them inside a customlistview.
If i select 2 from spinner1 i want that index removed from all other spinners in the activity as it have been already "used" so by expanding spinner2 that number will not be available: 1 (x) 3 4 5 6 7 8 9 10.
a chunk of code, how can i access the spinner options from here?
Thanks
My app have 10 spinner, every spinner have values from 1 to 10:
spinner1 = 1>10
spinner2 = 1>10 and so on.
All the spinners share the same event and i load them inside a customlistview.
If i select 2 from spinner1 i want that index removed from all other spinners in the activity as it have been already "used" so by expanding spinner2 that number will not be available: 1 (x) 3 4 5 6 7 8 9 10.
a chunk of code, how can i access the spinner options from here?
B4X:
Sub spnclick_ItemClick(position As Int, value As Object)
Dim spin As View = Sender
Log(spin.Tag&"TAG")
Log(value&"VALUE")
Log(position&"POSITION")
For Each v As View In Activity.GetAllViewsRecursive
If v Is Spinner Then
For k = 0 To 1
Log(Activity.GetView(k))
Log(v.Tag)
Next
End If
Next
End Sub
Thanks
Last edited: