java - How to change the background color for layouts using configuration file in android -


i want change background color layouts dynamically first time only, using configuration file in android file should in assets folder,it can xml file or anything. please me.

if set id layout follows :

<linearlayout android:id="@+id/mylayout"> <linearlayout/> 

then can set background in oncreate this:

mylayout= findviewbyid(r.id.mylayout); mylayout.setbackgroundcolor(color.blue); 

Comments

Popular posts from this blog

css - Text drops down with smaller window -

php - Boolean search on database with 5 million rows, very slow -

c# - DetailsView in ASP.Net - How to add another column on the side/add a control in each row? -