locked
Event when a control has been visible RRS feed

  • Question

  • What is the best way of triggering something right after a Control/UIElement has been loaded, layout updated and visually visible for the first time on the screen?

    Saturday, February 2, 2013 2:55 PM

Answers

  • The breaking point hits there because the root frame is the very first thing that loads, even before the splash screen. Think of the root frame as the visual host of your application. Or as a better analogy, think of it as a page which renders pages.

     Something did happen on the screen, only that it is invisible to our eyes.

    Take a look at this, it explains pretty well what the PhoneApplicationFrame is

    http://msdn.microsoft.com/en-us/library/windowsphone/develop/ff402536%28v=vs.105%29.aspx

    Sunday, February 3, 2013 9:21 AM

All replies

  • The LayoutUpdated event should fire just before the control is ready to be used.

    http://msdn.microsoft.com/en-us/library/system.windows.frameworkelement.layoutupdated(v=vs.95).aspx

    Saturday, February 2, 2013 3:10 PM
  • Try the loaded event.
    Saturday, February 2, 2013 4:48 PM
  • The phone application frame behaves differently because it is an entirely different type of class. If you want to know when it starts loading, the most close event to this would be OnNavigatedTo. In fact, this is probably as far down as you can go.


    • Edited by mcosmin Saturday, February 2, 2013 8:36 PM
    Saturday, February 2, 2013 8:30 PM
  • The breaking point hits there because the root frame is the very first thing that loads, even before the splash screen. Think of the root frame as the visual host of your application. Or as a better analogy, think of it as a page which renders pages.

     Something did happen on the screen, only that it is invisible to our eyes.

    Take a look at this, it explains pretty well what the PhoneApplicationFrame is

    http://msdn.microsoft.com/en-us/library/windowsphone/develop/ff402536%28v=vs.105%29.aspx

    Sunday, February 3, 2013 9:21 AM