Sent a Image from drawable to a ImageView?

Fation Joni

enter image description hereI'm working in a project called gift card, which is a simple app. When a user is in an activity, they can click in a photo and when they click, it will appear as background of another activity. I'm trying to solve this but nothing is working. Can you help me but please in a simple way because im a beginner in Android Studio. Thank You !!!

Access Denied

getDrawable(id) is deprecated since API 22. Now you need to specify Theme.

 getResources().getDrawable(id, context.getTheme());

In order to support previous android versions use the following:

ContextCompat.getDrawable(context, R.drawable.***)

Android getResources().getDrawable() deprecated API 22

Collected from the Internet

Please contact [email protected] to delete if infringement.

edited at
0

Comments

0 comments
Login to comment

Related

URL image to imageview to drawable

Copy Drawable From ImageView

Low quality image when setting an imageview drawable from a gridview

How to load GIF image from drawable folder into ImageView using glide?

How to set image for imageview and linear layout from Drawable path in android

Create dynamic thumbnail image from drawable resource and set to imageView

Comparing drawable image with imageview icon android?

Picasso doesn't load drawable image into ImageView

Setting ImageView's image from filepath. BitmapFactory.decodeFile, BitmapFactory.decodeStream or Drawable.fromFile?

Setting an ImageView from the drawable folder dynamicly

How to get drawable name from imageView

setting image drawable from a class

Set image from drawable to recyclerview

large resolution takes image from drawable instead of drawable-xxhdpi

Android load imageView with drawable depending on data received from firebase

Problem: No drawable files from Resource folder seen on ImageView

Unable to set ImageView within GridView to Bitmap converted from Drawable

How to load picture from @drawable to ImageView using fragments?

How to load an image from drawable and convert to a bitmap

Import image from Drawable imageResource Exception

How to create a drawable from an image in assets folder?

Libgdx get Texture from Image or Drawable

Converting an image from drawable to byte array in Android

Android - Load image from drawable to ViewPager

GIMP pythonfu get drawable from current image

Set background image not from drawable folder

Creating Image instance from drawable images in android

how to add image to listview from drawable

set Image from ImageView to Dialog