I have created a C# MDI app that launches multiple instances of child forms containing a treeView control. I populate the tree completely when the form loads and Memory increases about 10MB per instance of the form. On closing the child windows, the memory does not get recovered, even after calling GC.Collect(). After an hour my app is > 200MB. Any ideas? Help!!
UPDATE: I think I have resolved this...it seems to be a TreeView bug.
You have to clear all nodes from the treeview before closing the form or they do not get cleared even once the form is gone...I assume this should be handled by the control therefore a bug.
I do call GC.Collect() after as an added precaution.
PEPeteBApril 8, 2003 07:06 AM
FYI: This does appear to have been the issue. Clear all nodes before exiting Form with Treeview.