android pick images from gallery

前端 未结 10 1896
太阳男子
太阳男子 2020-11-22 13:53

I want to create a picture chooser from gallery. I use code

 intent = new Intent(Intent.ACTION_PICK, android.provider.MediaStore.Images.Media.EXTERNAL_CONTE         


        
10条回答
  •  梦谈多话
    2020-11-22 14:20

    U can do it easier than this answers :

    Uri Selected_Image_Uri = data.getData();
    ImageView imageView = (ImageView) findViewById(R.id.loadedimg);
    imageView.setImageURI(Selected_Image_Uri);
    

提交回复
热议问题