tags:

views:

11

answers:

1

Hello guys!

How can I change the place of the .sqlite file in my directory structure. Now it is in the Documents, but I want it to be in the Library/Preferences. Can you help me please?

+1  A: 

Assuming you have something like this in your code:

[NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES) lastObject];

Try replacing NSDocumentDirectory with NSLibraryDirectory.

I am not sure where and if you are allowed to write files there (except by using the sanctioned methods, of course).

Krumelur
Thanks a lot! :)
Infinity