On Jul 23, 2008, at 8:03 PM, Doug Knowles wrote:

- When Save As... is selected from the menu, our implementation
of writeToURL:ofType:error: is being called with an URL specifying a
location in a hidden temporary folder in the directory (in a shared
directory on a Windows machine) targeted by the user. We understand this to
be part of the normal behavior of NSDocument, ensuring that the write
completes successfully before putting the file in it's real destination. OK
so far.

- Stepping through this in the debugger, we can confirm that the file is
properly written to its destination in the temporary

- After we successfully write the file, an alert is displayed that reports that the document could not be saved. It appears that NSDocument is failing
to move the file to its proper location and reporting it as an error.

Is anything logged to the console when it fails to save? If you're on Leopard, FSPathReplaceObject is/was buggy, and there various cases where it fails, at least with NSSaveOperation:

http://www.cocoabuilder.com/search/archive/cocoa?words=FSPathReplaceObject

I reimplemented -[NSDocument writeSafelyToURL:ofType:forSaveOperation:error:] to work around the problems we had saving to AFP volumes.

--
Adam

Attachment: smime.p7s
Description: S/MIME cryptographic signature

_______________________________________________

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