Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Trying to access library with try...catch
private async Task<StorageLibrary> TryAccessLibraryAsync(KnownLibraryId library)
{
try
{
return await StorageLibrary.GetLibraryAsync(library);
}
catch (UnauthorizedAccessException)
{
...
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment