Skip to content

Instantly share code, notes, and snippets.

Created Jul 26, 2017
What would you like to do?
protected void onActivityResult(int requestCode, int resultCode, Intent data) {
super.onActivityResult(requestCode, resultCode, data);
if (resultCode == RESULT_OK && requestCode == GALLERY_REQUEST_CODE) {
try {
Uri selectedImage = data.getData();
InputStream imageStream = getContentResolver().openInputStream(selectedImage);
} catch (IOException exception) {
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment