[Expand]General Information
[Collapse]WinForms Controls
  .NET Core Support
 [Expand]What's Installed
 [Expand]Build an Application
 [Collapse]Controls and Libraries
  [Expand]Forms and User Controls
  [Expand]Messages, Notifications, and Dialogs
  [Expand]Editors and Simple Controls
  [Expand]Ribbon, Bars and Menu
  [Expand]Application UI Manager
  [Collapse]Docking Library
   [Expand]Panels and Panel Containers
    Header Buttons
   [Expand]Managing Dock Panels in Code
    Saving and Restoring the Layout of Dock Panels
     How to: Access auto-hidden panels
     How to: Add controls to a panel
     How to: Combine panels into a split container
     How to: Combine panels into a tab container
     How to: Create a dock panel
     How to: Create and float a panel
     How to: Display all the hidden panels
     How to: Dock panels to a form
     How to: Enable the auto hide feature for root panels
     How to: Override the default behavior of a panel when it is closed
     How to: Prevent dock panels from being docked to the form's right edge
     How to: Recursively iterate through the child panels of a specific panel
     How to: Transform a split container into a tab container
     How to: Write and read a docking layout to and from an XML file
     How to: Write and read a docking layout to and from memory
     How to: Write and read a docking layout to and from the system registry
  [Expand]Data Grid
  [Expand]Vertical Grid
  [Expand]Property Grid
  [Expand]Pivot Grid
  [Expand]Tree List
  [Expand]Chart Control
  [Expand]Map Control
  [Expand]Rich Text Editor
  [Expand]Spell Checker
  [Expand]Form Layout Managers
  [Expand]Navigation Controls
  [Expand]PDF Viewer
  [Expand]TreeMap Control
  [Expand]Sunburst Control
 [Expand]Common Features
  Get More Help
 [Expand]API Reference
[Expand]ASP.NET Controls and MVC Extensions
[Expand]ASP.NET Bootstrap Controls
[Expand]ASP.NET Core Bootstrap Controls
[Expand]WPF Controls
[Expand]Xamarin Controls
[Expand]Windows 10 App Controls
[Expand]Office File API
[Expand]Report and Dashboard Server
[Expand]eXpressApp Framework
[Expand]eXpress Persistent Objects
[Expand]CodeRush Classic
[Expand]Cross-Platform Core Libraries
[Expand]Tools and Utilities
 End-User Documentation
View this topic on docs.devexpress.com (Learn more)

How to: Combine panels into a tab container

In the following code two floating panels are created and then combined to form a single tab container. A tab container is created via the DockPanel.DockAsTab method and this method can be used to create new tabs in the created tab container later on.

Which tab in the tab container contains which panel is specified by this method's index parameter. In this example, the tab page containing the second panel (dp2) will be added to the first tab because the index parameter is set to 0.

The result is shown below:

Is this topic helpful?​​​​​​​