Crash when NSPersistentDocument tries to present error during saveDocument:

2008-12-27 Thread Jerry Krinock
I was hoping someone could give me a clue about what might be causing this repeatable crash I get when saving a (Core Data) NSPersistentDocument: #0 objc_msgSend #1 -[NSDocumentController(NSInternal) _fixedFailureReasonFromError:] #2 -[NSDocument _willPresentSavingError:forOperation:url:] #3

Re: Crash when NSPersistentDocument tries to present error during saveDocument:

2008-12-27 Thread Jerry Krinock
Well, the problem is not in my 200 lines of inserting objects, setting attributes and relationships into the document, because I removed and simply ran this: BmxBk* bmxBk = [documentController openUntitledDocumentAndDisplay:NO

Re: Crash when NSPersistentDocument tries to present error during saveDocument:

2008-12-27 Thread Kyle Sluder
On Sat, Dec 27, 2008 at 4:13 PM, Jerry Krinock je...@ieee.org wrote: BmxBk* bmxBk = [documentController openUntitledDocumentAndDisplay:NO error:error] ; [bmxBk setFileURL:[NSURL fileURLWithPath:docPath]] ; [bmxBk saveDocument:self] ;

Re: Crash when NSPersistentDocument tries to present error during saveDocument:

2008-12-27 Thread Jerry Krinock
Thank you, Kyle. Actually, since - saveToURL:ofType:forSaveOperation:error: has a setFileURL built into it, I don't need setFileURL: So, this works for creating an NSPersistentDocument programatically - (void)applicationDidFinishLaunching:(NSNotification *)aNotification {