I'm new to Android programming, so please let me know if I'm doing anything stupid. However, I currently have an array String[] gamesList
that is dynamically generated from a database.
I want to use each element of an array in a Spinner, but the Adapter has a method signature of (Context, int, int)
. The first and third inputs I can do, but the second is asking for the id of a resource; but I don't have a R.array.someRandomName
resource, I only have a local array.
Is there some way to make the array a resource, or if not, how do I do this?