views:

69

answers:

1

Hi,

I'm doing something with UIImagePickerController.

It works fine and the Picture browser does open, however, I get this message. "Failed to save the videos metadata to the filesystem. Maybe the information did not conform to a plist."

What could be causing that? That is caused by this line [self presentModalViewController:self.imgPicker animated:YES]; which is activated on a button click

Snippets of the code that I have below.

- (void)viewDidLoad {
self.imgPicker = [[UIImagePickerController alloc] init];
self.imgPicker.allowsImageEditing = YES;
self.imgPicker.delegate = self;  
}

- (IBAction)grabImage {
[self presentModalViewController:self.imgPicker animated:YES];
}

it's also removing images from documents directory and from resources folder. I can not understand why? does someone found the solution to this?

While i inspecting the method imagepickerdidfinishpickingmediawithinfo:(NSDictionary*)info i found that when i select a photo from saved album in simulator the dictionary only return two key/value pairs while it should return 4 key/value pairs. Here is the gdb Output of info dictionary

<CFDictionary 0x4892d00 [0x2071ca0]>{type = mutable, count = 2, capacity = 3, pairs = (
1 : <CFString 0x16a51fc [0x2071ca0]>{contents = "UIImagePickerControllerMediaType"} = <CFString 0x37a3904 [0x2071ca0]>{contents = "public.image"}
3 : <CFString 0x16a520c [0x2071ca0]>{contents = "UIImagePickerControllerOriginalImage"} = <UIImage: 0x4893c20>
)}
A: 

Did you ever find a solution? My app was working wonderfully, then all the sudden it started doing the same thing.

just_another_coder
Until now I'm sorry to say NO. But you could try this in new sdk. One thing i would like to tell you that put breakpoint on viewDidUnload and viewDidLoad in your view Controller form which you are presenting imagePickerController also try to put the function call to dismiss ModalViewController in very beginning/bottom of the delegate method didfinishpickingmediawithinfo. May be you got some.Let me know your results.
Rahul Vyas