Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
395
xamchart memory leaks
posted

Using the .NET Memory Profiler from http://memprofiler.com/ I am finding any xamchart I create is never garbage collected. I am even seeing the same behavior in the XamFeatureBrowser. CarouselPanels get reclaimed by the garbage collector but XamCharts never do. In my application it appears that the ThemeManger q and b instances are static and hold references to the charts? Am I supposed to call Dispose some where? Any help would be appreciated.

 The output below is from the .NET Memory Profiler

Reference 1
__________________
System.Windows FrameworkElement[ 0000114,870[3]
System.Collections.Generic List<FrameworkElement> 0000084,690._items
System.Windows ResourceDictionary 0000076,180._ownerFEs
System.Collections.Generic Dictionary<ResourceDictionary, ResourceDictionary>.Entry[ 0000061,616[0].value
System.Collections.Generic Dictionary<ResourceDictionary, ResourceDictionary> 0000061,618.entries
Infragistics.Windows.Themes ThemeManager q

Reference 2
___________________
System.Windows FrameworkElement[ 0000114,870[3]
System.Collections.Generic List<FrameworkElement> 0000084,690._items
System.Windows ResourceDictionary 0000076,180._ownerFEs
Infragistics.Windows.Chart XamChart 0000001,627.n
System.Windows.Media LinearGradientBrush 0000078,714._contextStorage
System.Collections Hashtable.bucket[ 0000078,678
System.Collections Hashtable 0000078,578.buckets
System.Windows ResourceDictionary 0000078,583._baseDictionary
System.Windows ResourceDictionary[ 0000078,577[0]
System.Collections.Generic List<ResourceDictionary> 0000078,574._items
System.Collections.ObjectModel ObservableCollection<ResourceDictionary> 0000078,237.items
System.Windows ResourceDictionary 0000078,228._mergedDictionaries
    bu 0000078,229.b
    bu a

Reference 3
_________________
System.Windows FrameworkElement[ 0000114,870[3]
System.Collections.Generic List<FrameworkElement> 0000084,690._items
System.Windows ResourceDictionary 0000076,180._ownerFEs
Infragistics.Windows.Chart XamChart 0000001,627.n
System.Windows.Media LinearGradientBrush 0000078,714._contextStorage
System.Collections Hashtable.bucket[ 0000078,678
System.Collections Hashtable 0000078,578.buckets
System.Windows ResourceDictionary 0000078,583._baseDictionary
System.Windows ResourceDictionary[ 0000078,577[0]
System.Collections.Generic List<ResourceDictionary> 0000078,574._items
System.Collections.ObjectModel ObservableCollection<ResourceDictionary> 0000078,237.items
System.Windows ResourceDictionary 0000078,228._mergedDictionaries
System.Windows ResourceDictionary[ 0000078,882[0]
Infragistics.Windows.Themes ThemeManager.a 0000078,883.values
Infragistics.Windows.Themes ThemeManager.a[ 0000061,597[4]
System.Collections.Generic SortedList<string, ThemeManager.a> 0000061,600.values
Infragistics.Windows.Themes ThemeManager b