set Child View Background Resource - Android User Interface

Android examples for User Interface:View Child

Description

set Child View Background Resource

Demo Code


//package com.java2s;

import android.view.View;

public class Main {
    public static void setBackgroundResource(View container, int id,
            int resource) {
        if (container == null)
            return;

        container.findViewById(id).setBackgroundResource(resource);
    }/*from ww w .j  a v  a2  s  . c o m*/
}

Related Tutorials