made_rdj made_rdj

Niner since 2011


  • Navigating and Passing Data between XAML Pages - Day 3 - Part 3

    I have a question related to the final part of this tutorial where Bob overrode the navigate to/from methods. He did this in order to ensure that previous input was stored and displayed correctly after navigating back through the hyperlink button. He stated that he needed to do this as the hyperlink button caused a new instance of the mainpage to be created.

    I am presuming that overriding the methods does not prevent the creation of a new main page instance but simply populates the new instance with the correct data.

    Does this mean that the application will now have 2 instances of main page loaded in memory? If yes, How do you ensure that your navigation from a hyperlink returns to the already instantiated page?

    You could possibly create an application with many means of navigating to a given page. Having multiple instance of the same page loaded into memory seems rather wasteful.