hi ,
I applied code is this;
Dim Newtab As TabPageAdv = New TabPageExt(FormName .Text)
AddHandler Newtab.Closing, AddressOf tabPageAdv1_Closing
Tabcontrol1.Controls.Add(Newtab)
Newtab.Tag = Form.Name
Form.Parent = Newtab
Form.Visible = True
Form.Dock = DockStyle.Fill
Tabcontrol1.SelectedIndex = Tabcontrol1.TabPages.Count - 1
Form.Select()
Private Sub tabPageAdv1_Closing(ByVal sender As Object, ByVal args As TabPageAdvClosingEventArgs)
Dim f As Form = CType(Application.OpenForms(Tabcontrol1.SelectedTab.Tag), Form)
f.Close()
End Sub
thanks for reply