Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to give colors for autocompletetextview in android?

How to give colors for autocompletetextview in android. I am using these two colors for background and text-color

android:background = "#000000" android:textclolor = "#ffffff".

But the problem is if i type some texts on autocompletetextview then the listable values are showing in white color and same to the text-colors too.

I can't able to fix only a color for the whole autocompletetextview. How to do this?

suggestions please!..

thanks in advance

like image 907
prabu Avatar asked Dec 17 '25 07:12

prabu


1 Answers

you can use android:popupBackground attributes in AutoCompleteTextView in layout xml. it works for your problem. As for example like this ...

<?xml version="1.0" encoding="utf-8"?>
<AutoCompleteTextView xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/autocomplete_country"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:background="#000000"
android:popupBackground="#ffffff"  />
like image 165
SAURABH_12 Avatar answered Dec 19 '25 21:12

SAURABH_12



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!