How do I read the value of the navigationParameter of OnNavigatedTo

Oct 26, 2014 at 7:52 PM
Edited Oct 26, 2014 at 7:53 PM
Hi all,

During app development I come across a strange issue. Let me explain.
From a View I pass a parameter when a user picks an item from a ListView. I use this code for it:
    <Core:EventTriggerBehavior EventName="SelectionChanged">
        <Core:NavigateToPageAction TargetPage="{Binding DesiredView}" Parameter="{Binding MyObject}"/>
When I set a break on the OnNavigatedTo routine of the DesiredView, I can read the navigationParameter. But how do I get to that parameter in (VB) code?

Please take a look at this image, where you can see that there is one object in the AddedItems list. But on the Command window, I get an "object reference not set" when I try to refer to that object. And that is what I also get when trying to use the AddedItems(0) object in code.

Link to image

What is wrong in my approach or assumption of the working of this feature?