Docking Tab for WinForms | ComponentOne
Docking Operations / Display Same Controls on Docking Tab Page
In This Topic
    Display Same Controls on Docking Tab Page
    In This Topic
    To display the first set of controls on DockingTabPage for the rest of the DockingTabPages without duplicating them, perform the following steps:
    1. Add a panel to the first DockingTabPage and then set its Dock property to Fill so it spans the whole DockingTabPage.
    2. Add the controls on the panel.
    3. In the SelectedIndexChanging event handler move the panel from the previous docking tab page to the new one.
      C#
      Copy Code
       private void c1DockingTab1_SelectedIndexChanging(object sender, C1.Win.Command.SelectedIndexChangingEventArgs e)
              {
                  this.dockingTab.SelectedTab.Controls.Add(myPanel);
              }