Using wpf: Loading the UI of a page, before it’s shown, Specfically, a website in a frame on newest questions tagged wpf – Stack Overflow

I have a program that shows a page, waits 6 seconds, and shows another page. It does this using a page wrapper page with a frame on it. I’ve bound the context of the frame to my viewmodel. When I want to change the current page being show I just update the view of the frame based on where I am in my list of pages I want to display. There are about 10 different pages it loops through and then it repeats.

case "WeatherRadarView.xaml":
    view = new WeatherRadarView();
    break;

I currently have my program create the next page when it shows the new current page, under the impression that the page could use that 6 seconds to fully load and be ready to show. My newest page simply consists of a frame that is showing a website with animated weather radar on it. The problem is, the frame doesn’t load the website until the page is displayed. I’d love to find a way to have it load the page before it’s displayed, otherwise it spends 4 out of it’s 6 seconds loading.

Could this be done by changing a propery on the frame? How I load the page? Where/when I set the source?

Thanks for any help/ideas!

See Answers


source: http://stackoverflow.com/questions/12040543/loading-the-ui-of-a-page-before-its-shown-specfically-a-website-in-a-frame
Using wpf: using-wpf



online applications demo