We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Windows Form place into Tabcontrol

Thread ID:

Created:

Updated:

Platform:

Replies:

131008 Jun 16,2017 02:25 AM UTC Jun 16,2017 12:53 PM UTC WinForms 1
loading
Tags: TabControlAdv
Jaka Pradesa
Asked On June 16, 2017 02:25 AM UTC

Hi.

how to place form into TabPageAdv using c#
this my script but not working corectly.

            PUK.PUKChart form = new PUK.PUKChart();
            form.TopLevel = false;
            Syncfusion.Windows.Forms.Tools.TabPageAdv newtab = new Syncfusion.Windows.Forms.Tools.TabPageExt(form.Text.ToString());
            this.tabData.Controls.Add(form);
            form.Parent = newtab;
            form.Visible = true;

but form place intab without any control on it.
thank.

Senthil Kumaran Rajan [Syncfusion]
Replied On June 16, 2017 12:53 PM UTC

Hi Jaka, 
 
Thanks for contacting Syncfusion Support. 
 
In the provided code example, the form has been directly added in the TabControlAdv. But we have to add the Form inside the TabPageAdv and add the TabPageAdv inside the TabControlAdv, by using the below code example. Please use the below code example and let us know whether the reported behavior has been resolved? 
 
Code Example[C#]: 
 
Form2 form = new Form2(); 
form.TopLevel = false; 
Syncfusion.Windows.Forms.Tools.TabPageAdv newtab = new Syncfusion.Windows.Forms.Tools.TabPageExt(form.Text.ToString()); 
//Add the TabPageAdv in the TabControlAdv 
this.tabControlAdv1.TabPages.Add(newtab); 
//Add the Form inside the TabPageAdv. 
form.Parent = newtab; 
form.Visible = true; 
 
 
We have prepared the sample for your reference and this can be downloaded from the below location. 
 
 
Also, refer the below screenshot for further reference. 
 
 
 
Regards, 
Senthil 


CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

;