当有人按后退键并进入 wp7 中的 xaml 站点时如何获取事件?

发布于 2024-11-26 06:02:42 字数 85 浏览 4 评论 0原文

当用户在页面 A 并转到页面 B 时,我如何获取事件。在页面 B 上,他按后退并返回页面 A。 需要确定何时发生这种情况,我该如何使用 wp7 做到这一点?

how can i get the event when the user is on page A and go to page B. on page B he press back and returns tu page A.
need to determin when this happen, how could i do this with wp7?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

暗藏城府 2024-12-03 06:02:42

处理页面导航的 OnNavigedTo 事件(无论是通过 NavigationService 的 Navigate 还是 GoBack 方法)没有有关您从哪个页面导航的事件信息,也没有有关您如何导航的事件信息。

简而言之:这是不可能的。我也想不出有什么好的理由。

The OnNavigatedTo event that handles navigation to a page, be it by NavigationService's Navigate or GoBack method, have no event information on from which page you navigated from, and neither about how you navigated.

So in short: It's not possible. And I can't imagine any good reason for it either.

极致的悲 2024-12-03 06:02:42

PhoneApplicationPage .OnBackKeyPress 完全可以完成您正在寻找的工作。

There is PhoneApplicationPage.OnBackKeyPress that does exactly the job you are looking for.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文