
This code docks the tool window to the right of another tool window tw2: tw.DockTo(tw2, DockOperationType.RightOuter) This code docks the tool window to the inner (closest to client area) bottom edge of the host container control: tw.DockTo(dockManager, DockOperationType.BottomInner)

This code docks the tool window to the outer left edge of the host container control: tw.DockTo(dockManager, DockOperationType.LeftOuter) The DockManager should be used as a dock target whenever the target is intended to be the host container control or the MDI area. The second parameter is a DockOperationType enumeration value. Its first parameter is the target dock object, which can be any IDockObject. The ToolWindow class has a DockTo method that is used to perform a number of different docking operations for the tool window. Docking a Tool Window to Another Dock Object Since the tool window inherits from ContainerControl, any number of controls can be added to it via its Controls collection. The child control is automatically set to DockStyle.Fill. Note how the DockManager that should be used to manage the tool window is passed in, as well as the child control to add to the tool window.
#Activedock 1 how to
This code demonstrates how to create a tool window in code: ToolWindow tw = new ToolWindow(dockManager, "TW Key", "TW Text", -1, childControl) However the parameterless constructor is reserved for internal code and should never be called. The ToolWindow class has several constructors available. Documents can be tool or document windows so it is important to remember that the functionality below describes any tool or document window that is active in the MDI area.
