locked
Problem when Navigating Between two projects in the same solution RRS feed

  • Question

  • I'm creating a game with monogame.So first I created a MonoGame Windows Store Project for write the game logic of the game.

    Then I created a MonoGame Windows Store(XAML) Project to create the initializing part(Starting menu kind of stuff of the game).

    Then I add these two projects to a one solution.Now I want to navigate from initializing project to game logic project for an button click event at the initializing project.

    I tried this,

     private void Button_Click_2(object sender, RoutedEventArgs e)
            {
    
                var x = new Frame();
                x.Navigate(typeof(MissionNarcotics.Game1));
    
                Window.Current.Content = x;
                Window.Current.Activate();
            }
    //Mission narcotics is the game logic project
    

    Then I'm getting this error,

    Error HRESULT E_FAIL has been returned from a call to a COM component.

    What can I do for this???

    Saturday, September 14, 2013 6:19 PM

Answers

  • Hi Shaspace,

    It sounds reasonable in C# but in vstudio 2012 can only create a single store app per-process lifecycle. I don't think it could be possible to build two projects at the same time. Why not put them in a whole project, simply include your pages in MonoGame Windows Store Project to MonoGame Windows Store(XAML) Project.

    Best Regards,

    --James


    <THE CONTENT IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND, WHETHER EXPRESS OR IMPLIED>
    Thanks
    MSDN Community Support

    Please remember to "Mark as Answer" the responses that resolved your issue. It is a common way to recognize those who have helped you, and makes it easier for other visitors to find the resolution later.

    Monday, September 16, 2013 6:15 AM
    Moderator