Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6340987
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 24, 20262026-05-24T19:56:28+00:00 2026-05-24T19:56:28+00:00

In the current released version of WP7 you have no programmatic control over the

  • 0

In the current released version of WP7 you have no programmatic control over the page stack.

I start at A, go to B, and then C. B is the data entry page for new items, so coming back from C I want to logically land at A. Currently I listen for navigation on B that comes from C and force another back onto A. However, the event doesn’t happen soon enough to stop the page from displaying on-screen.

A -> B -> C

C -> A

A is the top level list page. B is the new item page. C is the item detail page.

This only occurs on one form so far so my workaround is to override OnNavigatedTo in the page I want to skip, and call “go back” programmatically. However, this has the undesired effect of briefly showing the page and then immediately navigating off of it.

  • Is there a workable way to stop the flicker?
  • Should my workaround instead be to take full control of page navigation, including go backs? This will leave the page stack is a strange state, but that would be hidden from the user if I control all navigation.

I know there is a new feature in Mango to pop a page from the page stack programmatically, but I’m curious to know if there is a solution to the problem in the released version.

Another motivation for this is I don’t know what version will be best to target, the latest, or the one that is just enough for the app. For the time being I’m sticking with the live version.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-24T19:56:28+00:00Added an answer on May 24, 2026 at 7:56 pm

    I have stopped the flickering by making the root frame transparent for the duration of the skip. This example isn’t straight from my code.

    Firstly on the page you wish to skip, override OnNavigatedTo and test to see where you have come from (this is where my code gets specific, I keep track of where I am):

    protected override void OnNavigatedTo(NavigationEventArgs e)
    {
        // If I've come from page C, go back again.
        NavigationService.GoBack();
    }
    

    Secondly, in the main App.xaml.cs register an event handler for Navigating (I put it in public App() constructor):

    RootFrame.Navigating += RootFrame_Navigating;
    

    Finally, flesh them out to hide the frame and show it again for the duration of the skip:

        private bool _skipped;
    
        private void RootFrame_Navigated(object sender, NavigationEventArgs e)
        {
            RootFrame.Opacity = 100;
            RootFrame.Navigated -= RootFrame_Navigated;
        }
    
        private void RootFrame_Navigating(object sender, NavigatingCancelEventArgs e)
        {
            if (_skipped)
            {
                _skipped = false;
                RootFrame.Navigated += RootFrame_Navigated;
            } 
    
            if (e.NavigationMode == NavigationMode.Back &&
                e.Uri.OriginalString.Contains("ThePage.xaml"))
            {
                RootFrame.Opacity = 0;
                _skipped = true;
            }
        }
    

    The code to determine when to make the page transparent is also different in my actual code, but I’ve added an implementation to the answer for illustration. This is almost identical to the code in the recipe linked in another answer, but doesn’t involve needing to use a third party DLL.

    I provided my own answer because I’ve seen the sources provided in the other answers before, but never paid attention to the code for hiding the root frame. I am not using the Non-Linear Navigation Service, just the code fragment for frame transparency (I don’t need it to detect circular navigation as I’m well aware of the design choices I make in the app and can spot them myself 🙂

    This suffices as a workaround in the (currently) one case I have where I need to skip a page that doesn’t make sense when going back. I’d like to think when Mango comes out I will be best placed targeting the latest version, so this code will soon be defunct.

    Sources:

    • App Hub code recipe for Non-Linear Navigation
    • Non-Linear Navigation Service Blog Post
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I've released an app with a Core Data sqlite database. In the new version
Stupid question and treat me as completely a newbie to version control. I'm new
At my current job, it goes without question that if a new version of
current code I've built function to do something over collection of jQuery elements: var
I just saw castleproject.org has released the 2.0 version of monorail in January 2010
I'm going to do a new install of Wordpress. new 3.0 version is coming.
I'm working on my own open-source project. I've recently released the first workable version
I have a script that can lookup and output or write my current release
In my current project I'm getting some html templates (for a single page interface
In my current project I have to decide which technique to use when branching.

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.