Pregunta

I am using FutureAccessList with a FolderPicker so that I don't have to keep asking the User permission to access a folder. However, I am unsure of how to 'save' this Token, or save the result. If the User says "OK", you can access "this" folder, how will my application know that the next time it starts?

What do I need to save, where and how do I save it, and how do I check against it in the future? This question is related to my other question, and the solution I provided only partially works. It gets permission, but I am unsure how to keep that permission to check against it in the future.

¿Fue útil?

Solución

FutureAccessList token is just a string. You can store it in database, text file, in ApplicationData.LocalSettings, etc. Later you can read that token and submit in FutureAccessList.GetFileAsync to get access to user's file.

You can also find out what is in the list using StorageItemAccessList.Entries. this is a collection of the things you've added.

Licenciado bajo: CC-BY-SA con atribución
No afiliado a StackOverflow
scroll top