Pick image from default gallery images... from android
Intent intent = new Intent(Intent.ACTION_PICK, MediaStore.Images.Media.EXTERNAL_CONTENT_URI);
List<ResolveInfo> list = packageManager.queryIntentActivities(intent,
PackageManager.MATCH_DEFAULT_ONLY);
if (list.size() > 0) {
startActivityForResult(intent, PICK_IMAGE_REQUEST);
} else {
Toast.makeText(UserProfileEditActivity.this, "No app can perform this action", Toast.LENGTH_LONG).show();
return;
}
No comments:
Post a Comment
Note: Only a member of this blog may post a comment.