LoadLayout crashes

4 posts, 0 answers
  1. Adrian
    Adrian avatar
    10 posts
    Member since:
    Jun 2013

    Posted 16 Oct 2013 Link to this post

    Hi,

    I use version 2013.2.611.40

    My scenario is:
    1. Opening application.
    2. Adding RadPane with serialization tag = "abc"
    3. Saving layout.
    4. Closing application.
    5. Opening application.
    6. Loading layout..... than crash.

    Crash is probably because I didn't add RadPane with serialization tag = "abc" and while loading RadDocking cannot find such RadPane and crashes.

    Is this the case that loading process requires all the RadPane which were saved to be present during the load?
    If so, than this is a critical bug because layout cannot be loaded.

    Regards,
    Adrian
  2. Alek
    Admin
    Alek avatar
    78 posts

    Posted 21 Oct 2013 Link to this post

    Hello Adrian,

    Following the steps you've sent is in the thread we tried to reproduce the issue but we did not manage. As an attached file you can find the video showing our approach. Please take a look at it.

    For your convenience we have the project we used for testing uploaded in our file repository. You can download all projects by clicking here. The exact project you can find under Docking/SaveLoadLayout.

    Regards,
    Alek
    Telerik
    TRY TELERIK'S NEWEST PRODUCT - EQATEC APPLICATION ANALYTICS for WPF.
    Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
    Sign up for Free application insights >>
  3. UI for WPF is Visual Studio 2017 Ready
  4. Adrian
    Adrian avatar
    10 posts
    Member since:
    Jun 2013

    Posted 24 Oct 2013 Link to this post

    Hi,

    My previous description wasn't detailed enough. I have submitted a support ticked with example project showing the crash.
    Ticket ID: 750905
    Link to support ticket: http://www.telerik.com/account/support-tickets/view-ticket.aspx?threadid=750905
    Link to project: http://www.telerik.com/automated-testing-tools/ClientsFiles/68f0bc00-9d29-4ae4-b616-eab17e2486de_DockingLayout.zip


    Steps:
    1. Open application.
    2. Add Pane
    3. Save layout
    4. Close "Pane 3" - last added pane  OR  close and start application again.
    5. Load Layout -> Crash

    Another problem is that when I save layout, add pane (e.g. Pane 3) and than load layout Pane 3 is removed because it wasn't saved. It would be good to not saved pane to be preserved or to have such option at least. In other words, what was saved should be loaded but other stuff should stay at it is.

    Best Regards,
    Adrian
  5. Rosen Vladimirov
    Admin
    Rosen Vladimirov avatar
    640 posts

    Posted 28 Oct 2013 Link to this post

    Hello Adrian,

    I've already answered to your ticket, but I'll paste the answer here for your reference:

    When you save the layout, you save an instance of DockingFrame (the new added pane is from this class). But when you try to load the layout, RadDocking is trying to create a RadPane for it. In order to create a new DockingFrame instance, you have to use ElementLoading event and create it manually:
    void radDocking_ElementLoading(object sender, LayoutSerializationLoadingEventArgs e)
    {
        if (e.AffectedElementSerializationTag.Contains("DockingFrame"))
        {
            e.SetAffectedElement(new DockingFrame());
        }
    }

    Hopefully this helps. 

    Regards,
    Rosen Vladimirov
    Telerik
    TRY TELERIK'S NEWEST PRODUCT - EQATEC APPLICATION ANALYTICS for WPF.
    Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
    Sign up for Free application insights >>
Back to Top