Reputation: 17
I am working on an iPhone app. I am opening gallery from my app grammatically, and its working fine, but currently albums are displaying, but I want all images to be display(not all albums). So can anybody help me to achieve this? or is it possible or not?
My code is:
UIAlertAction *Gallery = [UIAlertAction actionWithTitle:@"Add Existing Photo"
style:UIAlertActionStyleDefault
handler:^(UIAlertAction * action)
{
[alertcontroller dismissViewControllerAnimated:YES completion:nil];
//
self.multipleImagePicker = [[RPMultipleImagePickerViewController alloc] init];
self.multipleImagePicker.sourceType = UIImagePickerControllerSourceTypePhotoLibrary;
// UIImagePickerController initialization
self.picker.mediaTypes = [NSArray arrayWithObject:(NSString *)kUTTypeImage];
// Photo Library
self.picker.sourceType = UIImagePickerControllerSourceTypePhotoLibrary;
[self presentViewController:self.picker animated:YES completion:nil];
}];
Upvotes: 0
Views: 360
Reputation: 1806
You need to change the sourceType
as UIImagePickerControllerSourceTypePhotoLibrary
.
Please go through apple document. UIImagePickerController
Upvotes: 1