打开FileOpenPicker终止应用程序
问题描述:
全部:
我遇到了一个非常奇怪的问题。如果我在模拟器或手机上运行我的应用程序并附带调试,一切正常。但是如果我在没有附加调试的情况下运行应用程序,应用程序会在文件选择器出现时终止。
I met a very strange problem. If I run my app on emulator or phone with debug attached, everything is ok. But if I run app without debug attaching, the app terminate when file picker appear.
如何调试此问题?
Ping
答
通常这是由于您的应用更改状态导致的异常
Usually this is due to an exception caused by your app changing state
要调试此项,请在调试器中启动应用程序。 到达您要调用选择器的位置,然后转到工具栏中的"Lifecycle Events"下拉菜单并"暂停"您的应用程序。
To debug this, Start the app in the debugger. Get to the point where you are about to invoke the picker, then go to the 'Lifecycle Events' pull down in the tool bar and 'Suspend' your application.