I've got a core-data document based app. I need to programmatically create or 
open a document at a programmatically chosen location and display it in a 
window. This is what I tried:

[[NSDocumentController sharedDocumentController] 
makeDocumentWithContentsOfURL:url ofType:mytype error:&error];
[[NSDocumentController sharedDocumentController] 
openDocumentWithContentsOfURL:url display:YES error:&error];

This opens a new window, but when I hit command-S to save it says it doesn't 
know where to save and prompts me, despite me having supplied the URL of where 
to save it. However the default location it prompts is the correct location.

Then after I save it, I was hoping just the call to 
openDocumentWithContentsOfURL: would open it again, but that doesn't seem to do 
anything.

Are there some other APIs I need to be looking at?





      
_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to [EMAIL PROTECTED]

Reply via email to