DockState Changed?

2 posts, 0 answers
  1. Veljko Janjic
    Veljko Janjic avatar
    20 posts
    Member since:
    Nov 2005

    Posted 13 Aug 2007 Link to this post

    Is it possible to handle the DockStateChanged event.
    E.g. I want to have toolbar button which shows/hides dock panel, and if panel is closed by clicking its x button, I need to refresh the state of a  toolbutton. However, I can't  figure out how to know when panel changes its dock state.

    Thanks in advance.
  2. Julian Benkov
    Julian Benkov avatar
    1135 posts

    Posted 20 Aug 2007 Link to this post

    Hi Veljko,

    you can use the DockingStateChanged event of the DockingManager and its arguments to check whether the DockPanel has been closed and to change the toolbar states:

    private void dockingManager1_DockingStateChanged(object sender, Telerik.WinControls.Docking.DockingChangedEventArgs e) 
        string message = "DockObject current state: "
        IDockable window = e.DockObject as IDockable; 
        if (window != null) message = window.Text + " current state: "; 
        AddLog(message + e.DockState, true); 
        AddLog("", true); 

    I hope this was helpful.

    Kind regards,
    Julian Benkov
    the Telerik team

    Instantly find answers to your questions at the new Telerik Support Center
  3. DevCraft R3 2016 release webinar banner
Back to Top