Once a DockableControlPane with a specified key is created and added either directly to a DockArea, or to a DockableGroupPane, how can you completely remove the DockableControlPane from the UltraDockManager control so that UltraDockManager.PaneFromKey("Key of the removed pane") returns Nothing?I have used Panes.Remove(MyPane), but an instance of the pane still resides within the UltraDockManager. I have also tried MyPane.Dispose() which still leaves an instance of a pane with the specified key in the UltraDockManager.How can a pane be completely destroyed?
Hello Kagel,
Thank you for your response.
As you can see on the page I've linked below, NetAdvantage 2010 Volume 2 is no longer being maintained. I tried your code in our latest version and I did not get any exceptions.
http://es.infragistics.com/help/product-lifecycle
I guess the bug is still present in version 10.2 ???
Here is my code
if (_groupList.Panes.Exists(key))
{
DockableControlPane pan = _groupList.Panes[key] as DockableControlPane;
_groupList.Panes.Remove(key);
pan.Dispose(); //???
}
if (!_groupList.Panes.Exists(key))
UserControl uc = ....
DockableControlPane pan = new DockableControlPane(key, title, uc);
_groupList.Panes.Add(pan); >>> bang, key already exists although the panes collection is emtpy ???
Is there any reasonable workaround ????
Hello,
I will be happy to assist you all with this issue.
Attached, you will find a sample that demonstrates what Mike Dour mentioned in his last post. Please run the sample and let me know if you have any questions regarding how to permanently remove a dockable control pane.
Is this issue fixed, I am running in to the same issue as reported here.
I agree. The pane is still in the collection. I have tried to Close the pane, Dispose the pane, and RemoveAt from the DockableControlPanesCollection. Nothing works that I have found. What I need is an example of the code to permanently remove a pane.