Hi, I have a MainForm which has tab Control and several independent form. I open each Individual From in the tab of the main form. A "Close Tab" button on the MainFrom closes the current tab, its implementation is below.
This closes the current tab but what I also need is to dispose the From whose tab is closed but I am not sure how to get the instance of the form.'
Any help is appreciated Thanks in Advance.
'Close the current tab
Private Sub CloseCurrentTab()
'Close the current tab
Dim tabPageSave As TabPage
tabPageSave = tcDisplayDetails.SelectedTab
tcDisplayDetails.TabPages.Remove(tabPageSave)
End Sub