UIKit NIB not loading in bundle-Collection of common programming errors

NSInternalInconsistencyException', reason: 'Could not load NIB in bundle: 'NSBundle  (loaded)' with name '_UIDocumentActivityViewController''

I’m creating a QLPreviewController, presenting it to show a PDF. I then tap the share button. It crashes.

I downloaded Apple’s Document Interaction example project. I put my PDF fetching class into there, fetched a PDF, display it.. and it works. No crash on the share button. Both are for targets 6.1. I tried setting Apple’s code to target iPad only like my project. Their code works, mine doesn’t, and I’m baffled. From the error message it sounds like a bug in the SDK but I can’t pinpoint it.

Have you seen this before?

    QLPreviewController *previewController = [[QLPreviewController alloc] init];

    [previewController setDataSource:self];

    [previewController setDelegate:self];

    [self presentViewController:previewController animated:YES completion:^{}];



#pragma mark QLPreviewControllerDataSource

- (NSInteger) numberOfPreviewItemsInPreviewController:(QLPreviewController *)controller {

    return 1;
}

- (id )previewController:(QLPreviewController *)controller previewItemAtIndex:(NSInteger)index {
    return [NSURL fileURLWithPath:self.pdfPath];
}

I tried removing the reference to the framework, deleting derived data, cleaning the project, readding the QuickLook framework. I did show in Finder in both Apple’s project & mine & they have the same path.

And same thing occurs when I use a UIDocumentInteractionController. That little overlay with the email/print etc options is not loading in my project.