New to Telerik UI for WinForms? Download free 30-day trial

Accessing DockWindows

The DockWindows property returns an array of all DockWindow in a RadDock instance and gives you two useful properties and one method:

  • ToolWindows: Returns an array of ToolWindows.

  • DocumentWindows: Returns an array of DocumentWindows.

  • GetWindows(DockState state): Returns an array of DockWindows that are put in a specific DockState. For example, the following code snippet will return an array of DockWindows that are currently hidden:

DockWindow[] hiddenWindows = radDock1.DockWindows.GetWindows(DockState.Hidden);

Dim hiddenWindows As DockWindow() = Me.RadDock1.DockWindows.GetWindows(DockState.Hidden)

You can get a desired ToolWindow\DocumentWindow by specifying its Name as an index:

DockWindow window1 = this.radDock1.DockWindows["Form1"];
// or simply
DockWindow window2 = this.radDock1["Form1"];

Dim window1 As DockWindow = Me.RadDock1.DockWindows("Form1")
' or simply
Dim window2 As DockWindow = Me.RadDock1("Form1")

See Also

In this article