Home  >  Forum  >  Android
Post New Query

Android - How to change ActionBar background color programmatically



Asked on September 15, 2015

How to change ActionBar background color in android programmatically




Replied on September 16, 2015
Write code in your activity class as follows.


ActionBar bar = getActionBar();
bar.setBackgroundDrawable(new ColorDrawable(Color.parseColor("#004D40")));

This will change background color as #004D40




Replied on September 16, 2015
Really Helpful. Thanks.

Write Answer






©2019 concretepage.com | Privacy Policy | Contact Us