本文介绍了等待DisplayActionSheet(...)立即返回null的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我在运行App后更改MainPage.之后,任何调用都将等待DisplayActionSheet(...)和await DisplayAlert(...)立即返回null.但仅在WindowsPhone上.您知道更改MainPage的正确方法吗?出现问题的来源 https://github.com/devcatch/MasterDetailAndActionSheet
I change the MainPage after run App.After that any calls await DisplayActionSheet(...) and await DisplayAlert(...) return null immediately. But only on WindowsPhone.Do You know right way to change MainPage?The source with problem https://github.com/devcatch/MasterDetailAndActionSheet
推荐答案
我本以为您必须在返回例如之前将DisplayActionSheet的响应分配给变量.
I would have thought that you would have to assign the response of the DisplayActionSheet to a variable before returning e.g.
代替:
return await DisplayActionSheet...
使用:
var response = await DisplayActionSheet...
return response;
这篇关于等待DisplayActionSheet(...)立即返回null的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!