I'd like to dispose the MdiChildForm in DockManger, when I close the tab.
I tried to dispose the DockableControlPane at TabClosing event handler, but it the MdiChildForm is not diposed completely.
So, the MdiChildForm is still working in the background.
Is there any way to dispose the MdilChildForm completely?
This is the code that I tried.
private void ultraTabbedMdiManager1_TabClosing( object sender, CancelableMdiTabEventArgs e ){ MdiChildForm form = e.Tab.Form as MdiChildForm;
if ( form != null ) { DockableControlPane pane = form.Pane;
pane.IsMdiChild = false;
if ( pane.Control != null ) pane.Control.Dispose(); //removes from DockManager collections
pane.Dispose();
e.Cancel = true; }}
Hello guidegi,
I am checking about the progress of this issue. Please let me know If you need any further assistance on this.
Thank you for getting back to us.
If you could provide us small application reproducing the behavior that you are seing will be glad to look into it further for you.
Thanks.
I had taken the code that I wrote previous post from this forum.
Mike Dour suggested the code to remove dockablepane from ultradockmanager.
http://ko.infragistics.com/community/forums/p/1113/18645.aspx#18645
However, I don't know why the form is always null in your code.
Do you have any idea to remove docablepane from dockmanager and dispose the form in docakblepan?
The 'form' is always null for me. I might be missing something here. Please take a look at my sample and make the needed modifications so I can examine a project which reproduces your issue.