Where to write application data

Igor de Oliveira Couto igor at semperuna.com
Fri Jun 7 05:17:43 EDT 2013

On 06/06/2013, at 12:40 PM, Devin Asay <devin_asay at byu.edu> wrote:

> For desktop applications, where can our applications legally write to for the three main OS's? I'm not talking about sandboxing for Mac App Store apps, just the normal place for writing application files.

Hello, Devin, 

Not very long ago, I had the same question, and several users contributed their knowledge and experience in the different platforms, helping me compile an answer: 

QUESTION: Where do folks put application-specific preferences on Mac, Windows and Linux? 

The answer I compiled from all replies and pointers received was: 

1) MacOS X Prefs Location: 
specialFolderPath("Home") & "/Library/Application Support/MyCompany/MyAppBundleID/" - - Apple requires you to use the application's bundle id for the *folder name* 

2) Windows Prefs Location: 
specialFolderPath("0x001a") & "/MyApp/" 

3) Linux Prefs Location: 
there does not seem to be a 'standard', but several programs seem to take the approach of creating a hidden folder in the user's home directory - specialFolderPath("Home") & "/.myapp/" 

4) iOS Prefs Location: 
specialFolderPath("library") & "/MyAppBundleID/" - Apple requires you to use the application's bundle id for the *folder name* 

5) Android Prefs Location: 

The information above will help you find or create the appropriate directory in which to save your *preferences* file. If you want to save *documents*, or other support files, the location may vary.

Lastly, in regards to the naming of the preferences file: it seems the preferences file itself can be called pretty much anything you want, as there do not seem to be any strict guidelines in any current platform. 

I hope this information helps!

Igor Couto
Sydney, Australia

More information about the Use-livecode mailing list