Studyxnet / FilePicker-Plugin-for-Xamarin-and-Windows

FilePicker Plugin for Xamarin and Windows
MIT License
74 stars 52 forks source link

Exception from HRESULT: 0x80070032 (WindowsPhone 8.1 Emulator) #7

Open miglrodri opened 8 years ago

miglrodri commented 8 years ago

I tested the code in Android and it worked fine. I have a PCL in Xamarin Forms.

I have this code: async void OnButtonClicked(object sender, EventArgs e) { await CrossFilePicker.Current.PickFile(); }

On WindowsPhone it throws this exception:

System.Exception was unhandled by user code HResult=-2147024846 Message=The request is not supported. (Exception from HRESULT: 0x80070032) Source=Windows StackTrace: at Windows.Storage.Pickers.FileOpenPicker.PickSingleFileAsync() at Plugin.FilePicker.FilePickerImplementation.<PickFile>d__0.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at System.Runtime.CompilerServices.TaskAwaiter1.GetResult() at AppFilePicker.PickerPage.<OnButtonClicked>d__1.MoveNext() InnerException:

Any ideas why this happening? I ticked on some capabilities so i don't think it's permission problems. Best Regards