setBackground()
method was added into API level 16. use setBackgroundDrawable()
instead....
Drawable imagebakground = new BitmapDrawable(getResources(),Imagebackground);
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.JELLY_BEAN) {
framelayout.setBackground(imagebakground);
} else {
frameLayout.setBackgroundDrawable(imagebakground);
}