Skip to main content

DockManager.ClosedPanel Event

Occurs after a panel has been closed.

Namespace: DevExpress.XtraBars.Docking

Assembly: DevExpress.XtraBars.v24.2.dll

Declaration

[DXCategory("Docking")]
public event DockPanelEventHandler ClosedPanel

Event Data

The ClosedPanel event's data class is DockPanelEventArgs. The following properties provide information specific to this event:

Property Description
Panel Gets the processed dock panel.

Remarks

The ClosedPanel event occurs after a panel has been closed. It serves as a notification and can’t be used to prevent a panel from being closed. To prevent a panel from being closed, handle the DockManager.ClosingPanel event. See this member’s description for more information.

When users click a Close button, panels change their visibility to “Hidden” and move to the HiddenPanels collection. This allows you to access closed panels and restore them. If you want the Close button to dispose of closed panels rather than move them to the HiddenPanels collection, handle the ClosedPanel event and destroy panels manually.

void DockManager1_ClosedPanel(object sender, DockPanelEventArgs e) {
    e.Panel.Dispose();
}
See Also