2X faster development
The ultimate WinForms UI toolkit to boost your development speed.
Clear the compilation errorThe 'Syncfusion.Windows.Forms.Tools.TabControlAdv' namespace does not contain a definition for NavigationControl. The NavigationControl property has been changed as TabPrimitives for v.4.4. TabPrimitives provides more flexibility and it allows users to add any number of buttons in the TabPanel. You can comment out the NavigationControl related code in the designer generated code and compile the solution to make it work properly To work with TabPrimitives TabPrimitives can be made visible by setting TabPrimitivesHost.Visible property to true. TabPrimitivesHost Click on the TabPrimitivesCollection to bring up a collection editor and add the TabPrimitives as shown below. https://help.syncfusion.com/windowsforms/tabcontroladv/tabprimitives_images/tabprimitives_img6.jpeg CollectionEditor To add the TabPrimitives programatically, C# using Syncfusion.Windows.Forms.Tools; this.tabControlAdv1.TabPrimitivesHost.Visible = true; this.tabControlAdv1.TabPrimitivesHost.TabPrimitives.Add(new TabPrimitive(TabPrimitiveType.FirstTab, null, Color.Empty, true, 1, "TabPrimitive0")); this.tabControlAdv1.TabPrimitivesHost.TabPrimitives.Add(new TabPrimitive(TabPrimitiveType.PreviousPage, null, Color.Empty, true, 1, "TabPrimitive1")); this.tabControlAdv1.TabPrimitivesHost.TabPrimitives.Add(new TabPrimitive(TabPrimitiveType.PreviousTab, null, Color.Empty, true, 1, "TabPrimitive2")); this.tabControlAdv1.TabPrimitivesHost.TabPrimitives.Add(new TabPrimitive(TabPrimitiveType.NextTab, null, Color.Empty, true, 1, "TabPrimitive3")); this.tabControlAdv1.TabPrimitivesHost.TabPrimitives.Add(new TabPrimitive(TabPrimitiveType.NextPage, null, Color.Empty, true, 1, "TabPrimitive4")); this.tabControlAdv1.TabPrimitivesHost.TabPrimitives.Add(new TabPrimitive(TabPrimitiveType.NextPage, null, Color.Empty, true, 1, "TabPrimitive5")); this.tabControlAdv1.TabPrimitivesHost.TabPrimitives.Add(new TabPrimitive(TabPrimitiveType.Close, null, Color.Empty, true, 1, "TabPrimitive6"));
C# // To generate click events for custom TabPrimitiveType private void tabControlAdv1_TabPrimitiveClick (object sender, Syncfusion.Windows.Forms.Tools.TabPrimitiveClickEventArgs e) { if (e.TabPrimitive.Name == "TabPrimitive7") { // Add the code here. } }
UG document link: https://help.syncfusion.com/windowsforms/tabcontroladv/events#tabprimitiveclick-event |
2X faster development
The ultimate WinForms UI toolkit to boost your development speed.
This page will automatically be redirected to the sign-in page in 10 seconds.