Cambiar la imagen de un ImageView

private Bitmap bm1, bm2;

amarilloOff.setImageResource(R.drawable.amarillo_off);
bm1 = BitmapFactory.decodeResource(getResources(), R.drawable.amarillo_on);
bm2 = BitmapFactory.decodeResource(getResources(), R.drawable.amarillo_off);

amarilloOff.setImageBitmap(bm1);

No hay comentarios:

Publicar un comentario