How to Pass The Value of a TextView to A Spinner?

Viewed 18

I have a TextView with the value "Dog" which is retrieved by scanning a QR code. I want to pass that value to my spinner as soon as it is retrieved so that the spinner displays "Dog" instead of the other items. The spinner contains the text "Dog" already in the dropdown. I am using sharedPreferences to send the value of the spinner to another activity. I am not sure if that is causing the issue. Any ideas would be very helpful.

*Kotlin preferred

0 Answers
Related