Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 3 years ago.
Improve this questionin my app i am 开发者_如何转开发using an Camera for an operation. i am able to open camera and i can work on it, but before opening the camera i want to have an option named Album. When i select this i want view the image stored in the android device so far that too in a grid view.
how to perform this...
If i am right what you want is to open up the gallery and view the images in it in a grid view. If this is what you are looking for following is a piece of code to do this.
Intent intent = new Intent(Intent.ACTION_PICK);
intent.setType("image/*");
startActivityForResult(intent, 1);
Write the above code in the click event of the "Album" button.Above code will open up the gallery and displays the images in default grid view. Hope this helps you.
精彩评论