How can I navigate through xaml pages with Monogame in a Windows Phone 8 project?

Posted by misiMe on Stack Overflow See other posts from Stack Overflow or by misiMe
Published on 2014-05-21T21:56:33Z Indexed on 2014/05/28 3:27 UTC
Read the original article Hit count: 213

Filed under:
|
|
|

I finished to develop an XNA game, then I created the Monogame project, and tested it on my device. Now I made some other pages such as an "about" page. How can I go to that page considering I have a Monogame project and just an XNA code? In particular inside my game I made a Main Menu where you can click the "about" button and know if someone has clicked: how can I link that event to the "go to about.xaml" function?

Inside XNA, update method:

if (about_button.IsClicked())
{
    // Go to about.xaml
}

I tried:

   if (about_button.IsClicked())
    {
         ((PhoneApplicationFrame)Application.Current.RootVisual).Navigate(new Uri("/About.xaml", UriKind.Relative));
    }

But it throws: System.UnauthorizedAccessException

© Stack Overflow or respective owner

Related posts about c#

Related posts about windows-phone-8