I'm using this code to bring one control from form1 to form2:
Everything is fine. But the problem is that the tabcontrol permanently disappeared from form1 and I can't send back the tabcontrol. Something like this will work:
But the problem is that the TabControl1 don't exist in form2 until I send it to it.
I don't ask to use the same tabcontrol at the same time on two different times. I just want to send it back to it's original form.
I know that is a variable that keeps track of that tabcontrol. It is form1.tabcontrol, even if it is actually moved to form2 and I tried this code: (But it also doesn't worked...)
Please help me! :(
Code
Me.Controls.Add(Form1.TabControl1)
Me.Panel1.Size = Form1.TabControl1.Size
Form1.TabControl1.SelectedTab.Show()
Form1.TabControl1.Location = Me.Panel1.Location
Panel1.Hide()Everything is fine. But the problem is that the tabcontrol permanently disappeared from form1 and I can't send back the tabcontrol. Something like this will work:
Code
Form1.Controls.Add(Me.TabControl1)But the problem is that the TabControl1 don't exist in form2 until I send it to it.
I don't ask to use the same tabcontrol at the same time on two different times. I just want to send it back to it's original form.
I know that is a variable that keeps track of that tabcontrol. It is form1.tabcontrol, even if it is actually moved to form2 and I tried this code: (But it also doesn't worked...)
Code
Form1.Controls.Add(Form1.TabControl1)Please help me! :(


![[Image: 86251a37e635a21aea7eb7e014b0d820.gif]](https://i.gyazo.com/86251a37e635a21aea7eb7e014b0d820.gif)