Answer the question
In order to leave comments, you need to log in
How to make the text in the spinner be from 1 to the value specified in PlainText?
How to make the text in the spinner be from 1 to the value specified in PlainText? There is this code:
var data = MutableList(1, {x -> "${x+1}"})
val adapter = ArrayAdapter([email protected] , android.R.layout.simple_spinner_item, data)
adapter.setDropDownViewResource(android.R.layout.simple_spinner_dropdown_item)
spinner.adapter = adapter
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question