Reputation: 13359
I am working on Android application.I am using Spinner control and added items to it.
Is there a way to change the background color of items in spinner.
can any one help me in sorting out this issue.
Thanks in Advance,
Upvotes: 2
Views: 12075
Reputation:
You can also use android:popupBackground="YOUR COLOR"
which will define the items background not the whole spinner's background.
Upvotes: 0
Reputation: 1012
If you completely want to customize your background spinner, you should use 9patch background.
Here is a tutorial that explain how to do that : http://www.gersic.com/blog.php?id=57
Otherwise, the solution given by user432209 is the simplest. However, if you want to do that in xml layout :
<Spinner android:id="@+id/spinner"
...
android:background="#YOUR_HEXA_COLOR"/>
Upvotes: 2