0
votes

How to Programatically access the local OneDrive Folder on my system (Windows 10 Laptop) from UWP Windows 10 App?

There will be One Drive folder on every system , so my requirement is that i want to programatically access the that OneDrive folder on the system (My local Windows 10 laptop) From my Windows 10 UWP app.

Is there any way in which i can achieve this?

enter image description here

1

1 Answers

1
votes

I believe that there are no way to access the onedrive folder FULL programatically from your UWP. OneDrive folder is not assigned as "Special folders" like as pictures, documents, etc.

One workaround is ... ask the user to pick the folder of onedrive by FolderPicker.PickSingleFolderAsync, only once. You can save the storagefolder object to MRU or FAL list, and reuse it later.

For details, please refer the following link:

https://msdn.microsoft.com/en-us/windows/uwp/files/how-to-track-recently-used-files-and-folders

Note - Only the configured Win10 "PC" have the local onedrive folder. Other Win10 family - mobile, hololens, xboxone, etc - does not have it.