I am trying to put a copy of the database file used by my app, on OneDrive to allow syncing of data across multiple devices. When I try to open the db file to read it, an "Access denied" exception is thrown. Here is the code that's failing:
var stream = await ApplicationData.Current.LocalFolder.OpenStreamForReadAsync(dbFile)
This code also fails with the same error:
var files = await ApplicationData.Current.LocalFolder.GetFilesAsync()
So it appears that it may be access to the LocalFolder that's being denied.