I want to be able to change the background color to white in my android app in the simplest way possible.
+1
A:
You need to use the android:background property , eg
android:background="@color/white"
Also you need to you need to add a value for white in the strings.xml
<color name="white">#FFFFFF</color>
Ravi Vyas
2010-05-01 05:36:00
ryan please see my edited answer , this works
Ravi Vyas
2010-05-01 21:29:36
thank you it works now
ryan
2010-05-04 02:15:19
A:
You can also use
android:background="#ffffff"
in your xml layout, or you can change the theme in your AndroidManifest.xml by adding
android:theme="@android:style/Theme.Light"
to your activity tag.
If you want to change the background dynamically, use
YourView.setBackgroundColor(Color.argb(255, 255, 255, 255));
James
2010-05-02 15:23:29