Android Unable To Change Background Color Of ActionBar
I'm trying to change the background color of my Actionbar, but after referencing the several other questions on this site I still can't get their solutions to work. Styles.xml &l
Solution 1:
<style name="AppTheme" parent="@style/Theme.AppCompat.Light.DarkActionBar">
<item name="android:actionBarStyle">@style/ActionBarStyle</item>
<item name="actionBarStyle">@style/ActionBarStyle</item>
<item name="android:windowActionBar">true</item>
</style>
<style name="ActionBarStyle" parent="Widget.AppCompat.ActionBar">
<item name="background">@color/blue</item>
<item name="android:background">@color/blue</item>
</style>
Solution 2:
You can use this,
getSupportActionBar().setBackgroundDrawable(new ColorDrawable(Color.parseColor("#Color_Code")));
Solution 3:
Maybe you should edit styles.xml
at values-v14
folder.Because your min version is 19.
Post a Comment for "Android Unable To Change Background Color Of ActionBar"