0

In my iPhone app , when I use UIImagePickerControllerSourceTypePhotoLibrary as the source type, after opening it for 5 times , I get :

<Error>: More than maximum 5 filtered album lists trying to register. This will fail.

in my console.And also the image picked is gone.

if ([UIImagePickerController isSourceTypeAvailable:UIImagePickerControllerSourceTypePhotoLibrary]==YES) {

UIImagePickerController *imagePicker = [[UIImagePickerController alloc] init];
imagePicker.delegate = self;    
imagePicker.allowsEditing = YES;
imagePicker.sourceType = UIImagePickerControllerSourceTypePhotoLibrary;
[self presentModalViewController:imagePicker animated:YES];
[imagePicker release]; 
}

And in method:

- (void)imagePickerController:(UIImagePickerController *)picker didFinishPickingMediaWithInfo:(NSDictionary *)info

I dismiss the modalviewController.

0

1 Answer 1

0

It is related to creating multiple UIImagePickerControllers. You're only presenting one image picker controller at a time, so maybe you should create one the first time you call your grabImage and then reuse it instead of creating a new one each time.

Refer this and this and also this links

2
  • I have it initialized in viewDidLoad method and it is allocated only once and released in dealloc method
    – AJS
    Aug 28, 2012 at 12:50
  • i think its better to ignore it Aug 29, 2012 at 5:02

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.