Reputation: 2526
In Windows Phone and Windows 8.1, OnNavigatedTo would be invoked when a page became the visible page after navigation from any page. Now, it seems that this method is only called when switching between pages in the current app. How do I execute code when a user switches back to my app from another one (ie using the back button). I've tried the Application.Resuming event, but this is not fired either.
Upvotes: 0
Views: 94
Reputation: 5518
The Application.Resuming
event is only called if your app was actually suspended, which might not be the case. However, the application object has OnActivated
plus a bunch of scenario-specific overrides; one of those is likely what you want.
Relying on Window.VisibilityChanged
sounds iffy if you're targeting other device families than phone.
Upvotes: 0