0

I have written a simple app and would like to include a photograph from the users phone. They would be asked to choose a photo on their phone ... Can anyone give any suggestions or helpful advice on how I could do this. It is my first ever app so I am not extremely knowledgeable in this area.

Beth Ann Meredith
  • 181
  • 1
  • 4
  • 10

1 Answers1

0

use a button with onclicklistener(), and add this code in the loop.

Intent galleryIntent = new Intent(Intent.ACTION_PICK,
                                   android.provider.MediaStore.Images.Media.EXTERNAL_CONTENT_URI);
startActivityForResult(galleryIntent, Constants.REQ_CODE_PICK_IMAGE); 
Vinod Kumar
  • 312
  • 4
  • 10