Re: Modifying the save path in an NSDocument based application

2013-09-19 Thread Pax
The answer, if anyone else is thinking of answering this question, is to use NSFileWrapper - ensuring that Document is distributed as a bundle is unchecked for the folder that you generate. Simples. And my apologies to all here for not investigating further before posting a question. On 18

Re: Modifying the save path in an NSDocument based application

2013-09-18 Thread Pax
Okay, the plot thickens. I've now updated my app for the app store - sandboxing is now enabled. Sandboxing breaks the save path modification, and particularly my creation of a folder: if(![fileManager createDirectoryAtPath:directory

Modifying the save path in an NSDocument based application

2013-09-17 Thread Pax
I have a slightly odd requirement in that I need to modify, under certain circumstances, the save path used for an NSDocument based application. The reason for this is that I may, depending on the format chosen by the user, need to unpack the data into multiple files. Under this circumstance,

Re: Modifying the save path in an NSDocument based application

2013-09-17 Thread Steve Mills
On Sep 17, 2013, at 07:49:56, Pax 45rpmli...@googlemail.com wrote: I have a slightly odd requirement in that I need to modify, under certain circumstances, the save path used for an NSDocument based application. The reason for this is that I may, depending on the format chosen by the user,

Re: Modifying the save path in an NSDocument based application

2013-09-17 Thread Jerry Krinock
On Sep 17, 2013, at 07:49:56, Pax 45rpmli...@googlemail.com wrote: I thought that this would be nice and simple No. Overriding anything in the AppKit document architecture is playing with fireworks, especially since Auto Save and Versions. To be safe, when you're done, retest all of the

Re: Modifying the save path in an NSDocument based application

2013-09-17 Thread Pax
Thanks Jerry, Thanks Steve, You guys rock! If you're ever in London I definitely owe you beer! On 17 Sep 2013, at 14:41, Steve Mills smi...@makemusic.com wrote: You might try overriding saveToURL:ofType:forSaveOperation:completionHandler: instead. writeToURL is at a very low level in the