RadDocument and backgroundworker

4 posts, 0 answers
  1. Alois
    Alois avatar
    6 posts
    Member since:
    Feb 2011

    Posted 21 Dec 2011 Link to this post

    Hi,

    is it possible to work programatically with RadDocument within an backgroundworker thread ?
    For example execute a call like: RadDocument oDoc = new (RadDocument)

    Kind regards
    Alois
  2. Iva Toteva
    Admin
    Iva Toteva avatar
    1319 posts

    Posted 23 Dec 2011 Link to this post

    Hello Alois,

    You can create documents programmatically following the structure of the document outlined in this picture, i.e. create a Section, different Paragraphs and Tables, Spans with different text, etc.
    However, this cannot happen on a background thread for now. We have this limitation on our to-do list, but it is still not certain when it will be addressed.

    Regards,
    Iva Toteva
    the Telerik team

    Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

  3. DevCraft banner
  4. Mahendran
    Mahendran avatar
    1 posts
    Member since:
    Oct 2012

    Posted 20 Mar 2013 Link to this post

    Hi,

    Can we process RadDocument in BackGroundWorker Thread and pass it back to UI thread. couple of reasons,
    1) to get the busy indicator working freeing up the UI Thread.
    2 ) avoid UI Flickering during rebind 

    Regards,
    Mahendran
  5. Iva Toteva
    Admin
    Iva Toteva avatar
    1319 posts

    Posted 25 Mar 2013 Link to this post

    Hi Mahendran,

    As explained above, currently it is not possible to manipulate RadDocument on a thread different than the UI thread in Silverlight, because the creation of some document elements require that UIElements would be created for them.

    What you can try is to create the documents server-side, using the WPF version of the controls. Then, you can export them to XAML and send them to the client via a web service. The service can be consumed asynchronously, so in theory it should be possible to show a busy indicator in the meantime. Please, have in mind that the documents must be created in a STA Thread on the server. 

    Greetings,
    Iva Toteva
    the Telerik team

    Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

Back to Top