locked
Large Dynamic UI- Freezes SL RRS feed

  • Question

  • I have a dynamic UI which requires hundreds of controls and their connected objects to load on demand. These cannot be prebuilt or defined, and are read from xml to get their various properties, position and content.

    When doing this, it does as you would expect, freeze SL and the browser (and of course any possible busyindicator), since it is UI elements being dynamically created, I cannot put that on another thread.

    Anyone got any idea's or suggestions that will help me display something to let the use that the system is busy?

    Thanks,

    Pete

    Sunday, November 14, 2010 2:04 PM

Answers

  • I'm not sure if this works but could you add the controls to another control (Grid, StackPanel, ...) that's not part of the current page. When all the controls are placed to that control, add the control to the current pages visual tree. You could also do this in another thread and just use the UI thread for attaching the final control. 

    Monday, November 15, 2010 5:49 AM
  • You could try to add your controls in "small" batches using a timer or something like that.

    Monday, November 15, 2010 9:07 PM

All replies

  • I'm not sure if this works but could you add the controls to another control (Grid, StackPanel, ...) that's not part of the current page. When all the controls are placed to that control, add the control to the current pages visual tree. You could also do this in another thread and just use the UI thread for attaching the final control. 

    Monday, November 15, 2010 5:49 AM
  • You could try to add your controls in "small" batches using a timer or something like that.

    Monday, November 15, 2010 9:07 PM