0

I wonder if its possible to disable the OnNavigatedTo event in windows phone application. Why I would like to do this is beacuse when I navigate in the app everything works as I want.

But when I go to the homescreen and back to the application when it resumes it does OnNavigatedTo and I only want that to be fired as long as you navigate between pages in the application.

Is this possible?

Robin M
  • 41
  • 1
  • 8

1 Answers1

0

set a static Boolean flag as false, when u going out from the application (homescreen OnBackKeyPress) & set it as true when app starts(homescreen OnNavigatedTo).
now check this flag on every OnNavigatedTo of pages wherever u need.

Ashok Damani
  • 3,896
  • 4
  • 30
  • 48
  • Now I did it like this: **Boolean backnav = false;**, then for OnNavigatedTo I set it as true **backnav = true** have i understand it correct? But what happens when i press the **homebutton** – Robin M Aug 09 '13 at 09:17
  • 1
    @RobinM you can't disable or change the behaviour of the Home button, it will always suspend the current app and return the user to the Start Menu. – Neil Turner Aug 09 '13 at 14:15
  • I dont want to change it. I just want the OnNavigatedTo not to fire when you resume the app, so there is no protected ovveride for home button – Robin M Aug 10 '13 at 06:43