Telerik.WinControls.Docking and the 2011.Q1 version.

5 posts, 0 answers
  1. Jill-Connie Lorentsen
    Jill-Connie Lorentsen avatar
    118 posts
    Member since:
    Nov 2008

    Posted 05 Apr 2011 Link to this post

    I am now going to work on a project that I haven't worked on for a year or so (my co-workers have), and that has caused some problems for me.

    I have a new, fresh computer, and installed the Telerik 2011.Q1 components. My project make use of the DocumentManager and DocumentPane from the now obsolete Telerik.WinControls.Docking, so I decided to convert to RadDock, but it is easier said than done.

    I cannot open my form in design mode because the Telerik.WinControls.Docking is missing. If I add a reference to the 2010.3 version of this dll (without installing the entire package) I get an error saying that Visual Studio has encountered an error and needs to close, could not load file or assembly Telerik.Wincontrols.UI version 2010.3. 

    In your article http://www.telerik.com/help/winforms/dock-upgrading-from-dockingmanager-to-raddock.html it says that I need to have both versions installed, but this article refers to versions older than mine. Is this the way to solve this?

    Or is it a way that I can fix it in my code?

  2. Jill-Connie Lorentsen
    Jill-Connie Lorentsen avatar
    118 posts
    Member since:
    Nov 2008

    Posted 06 Apr 2011 Link to this post

    While waiting for a response I installed the 2010.Q3 version, and my form opened in design mode! I followed the procedure in the above mentioned article, but after pressing Process to perform the conversion I get an error saying

    Visual Studio is attempting to load class instances from a different assembly than the original used to create your components. This will result in failure to load your designed component. More information that will help you correct the problem:

    Component assembly: C:\Windows\assembly\GAC_MSIL\Telerik.WinControls.RadDock\2010.3.10.xxx\Telerik.WinControls.RadDock.dll

    Designer assembly: C:\Windows\assembly\GAC_MSIL\Telerik.WinControls.UI.Design\2011.1.xxx\Telerik.WinControls.UI.design.dll

    Pressing OK gives another error:

    Cannot find type Telerik.WinControls.IMessageListener in module TelerikCommon.dll

    I cannot find the path in the first error on my computer, and I cannot find IMessageListener in my project...

    I'm getting more and more confused and frustrated, so I hope somebody can give me some guidelines.

  3. UI for WinForms is Visual Studio 2017 Ready
  4. Nikolay
    Admin
    Nikolay avatar
    1803 posts

    Posted 06 Apr 2011 Link to this post

    Hi Jill-Connie Lorentsen,

    Thank you for writing.

    Indeed, I would suggest that you install Q3 2010 which still contains the old DockingManager and the converter to the new RadDock. Please note that after you change the references from Q1 2011 to Q3 2010, you should close the Visual Studio instance that has your project opened. Visual Studio keeps objects from both versions in its static memory, so it is necessary to clean this memory by closing and then reopening the Visual Studio itself. This will allow you to use Q3 2010 and its conversion wizard. If you continue experiencing issues, please uninstall Q1 2011 and then try using the wizard again.

    I hope this helps.

    Kind regards,
    Nikolay
    the Telerik team
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
  5. Jill-Connie Lorentsen
    Jill-Connie Lorentsen avatar
    118 posts
    Member since:
    Nov 2008

    Posted 06 Apr 2011 Link to this post

    Thank you, that helped! But I am not quite done.

    What is the equivalent to Telerik.WinControls.Docking.DockPanel and DockContextMenu?

    I also have problem with the event handler. Please look at the code below. cmContent was a DockingManager, and now is RadDock. I get errors on DockingChangedEventArgs,e.DockObject, DocumentPane, e.DockState, dp.MdiChild, cmContent.RemoveDocument...



    private void cmContent_DockingStateChanged(object sender, DockingChangedEventArgs e)
            {
      
                if (e.DockObject is DocumentPane)
                {
                    if (e.DockState == DockState.Hidden || e.DockState == DockState.Default)
                    {
                        var window = e.DockObject as IDockable;
      
                        if (window == null)
                        {
                            return;
                        }
      
                        var dp = e.DockObject as DocumentPane;
      
                        if (dp.MdiChild != null)
                        {
                            dp.MdiChild.Close();
                            dp.MdiChild.Dispose();
                            cmContent.RemoveDocument(window);
                            GC.Collect();
                        }
                    }
                }
                   
                if(_currentMdi != null)
                {
                    cmContent.ActivateMdiChild(_currentMdi);
                }
            }

    Your help is appreciated!

    Regards, Jill-Connie Lorentsen

  6. Nikolay
    Admin
    Nikolay avatar
    1803 posts

    Posted 07 Apr 2011 Link to this post

    Hello Jill-Connie Lorentsen,

    Please refer to the Q2 2009 Release Notes. They contains a comparison table between the API of DockingManager and RadDock.

    As to the DockContextMenu, please refer to this article which explains how you can access and modify the context menus of the new RadDock.

    Best wishes,
    Nikolay
    the Telerik team
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
Back to Top
UI for WinForms is Visual Studio 2017 Ready