I'm trying to link my photo library to display an image in the UIImageView which will allow me to add filters, but when you select the photo and hit 'Choose' the app crashes. Below is the code I'm using; - (IBAction)chooseImage:(id)sender {
UIImagePickerController *picker = [[UIImagePickerController alloc] init];
picker.delegate = self;
picker.allowsEditing = YES;
picker.sourceType = UIImagePickerControllerSourceTypePhotoLibrary;
[self presentViewController:picker animated:YES completion:nil];
}
The error is in the line:
"picker.delegate = self;"
and is noted as *"Assigning to 'id' from incompatible type 'VSViewController const_strong'
Please if anyone has a suggestion on how to fix it or an alternate code that will operate, that would be appreciated.
Please try to avoid over complex language, I'm new to coding and this issue has been frustrating me for a while.