Skip to main content

DockManager(ContainerControl) Constructor

Initializes a new instance of the DockManager class with the specified container control.

Namespace: DevExpress.XtraBars.Docking

Assembly: DevExpress.XtraBars.v24.2.dll

Declaration

public DockManager(
    ContainerControl form
)

Parameters

Name Type Description
form ContainerControl

A ContainerControl object representing the container control that will display the dock panels owned by the created dock manager.

Remarks

The constructor initializes all the fields to their default values.

The form parameter is used to initialize the DockManager.Form property. It represents the container control (form or user control) that will display the dock panels owned by the dock manager. The DockManager.Form property must refer to a valid control (not null), otherwise an exception will occur when adding panels to the dock manager.

Example

The following code shows how to add a dock manager to a form and create a panel.

using DevExpress.XtraBars.Docking;
// ...
// Create a dock manager
DockManager dm = new DockManager();
// Specify the form to which the dock panels will be added
dm.Form = this;
// Create a new panel and dock it to the left edge of the form
DockPanel dp1 = dm.AddPanel(DockingStyle.Left);
dp1.Text = "Panel 1";

The following code snippets (auto-collected from DevExpress Examples) contain references to the DockManager(ContainerControl) constructor.

Note

The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.

See Also