Search code examples
uwpwindows-10-universal

LocalFolder vs LocalSettings


Based on the information at https://learn.microsoft.com/en-us/uwp/api/Windows.Storage.ApplicationData

LocalFolder is the root folder in the local app data store and this folder is backed up to the cloud.

LocalSettings is the application settings container in the local app data store.

I'd like to know if LocalSettings is also backed up to the cloud so my users settings will be restored if they uninstall and reinstall the app, or would I be better off making my own settings file in LocalFolder?

Thanks in advance,

Stu


Solution

  • Generally local data exists along with the app, however if the user activates App Data Backup then they can be backed up to the cloud and then used for reseting the device (here is a very good description of local/cache/temporary):

    During a device backup operation, the system will grab any app data in Local and store it as part of a device backup image in OneDrive. If the user resets or replaces the device, he or she will be given the choice to restore a previous backup, which will restore the app data in Local as part of the app’s installation. Note that by not storing data in Local you will effectively be opting out of backup for your app.

    AFAIK the above is only for device restoration/replacement. When you uninstall and install the app, the Local data won't be there.