Hello.
I have a XamGrid with ItemsSource binded on List<>. For example, there are 4 items in collection.
Also, there is a "refresh" button, that creates new List<>
For test memory leak I use ObjectTracker from:
http://davybrion.com/blog/2009/08/tracking-dangling-object-references-in-silverlight/ .
I press "refresh" button some times and see how many tracked objects not GCed.
code in "refresh" button:
public int TrackingObjectsCount { get { return ObjectTracker.GetAllLiveTrackedObjects().Count(); } } void btn1_Click(object sender, RoutedEventArgs e) { Collection = new List<TestClass> { new TestClass{Name = "name1",Age = 1}, new TestClass{Name = "name2",Age = 2}, new TestClass{Name = "name3",Age = 3}, new TestClass{Name = "name4",Age = 4} }; foreach (var testClass in Collection) { ObjectTracker.Track(testClass); } RaisePropertyChanged("TrackingObjectsCount"); }
As I understand, because List<> creates each time with new items, they should be GCed, but they not.
For example, on first click I have 4 live objects, on second 8 and so on.
It seems that XamGrid still has references on them.
You can see a code example on attached file.
There is an official XamGrid bug?
If you have a questions, please ask. I'm not sure in my english :)
Test Project zip file:
BR,
Alexey Lukyanov
Hello Alexey,
As Steve mentioned, this issue has been logged in our system and has an ID of 67704. I have created a private case for you that can be used to track the status of this issue and will also notify you when this fix is available in a public service release.
You can view the status of all development issues connected to this case from the "Development Issues" tab, when viewing this case on the "My Support Activity" page of our website.
Thank you, guys!
I am glad such a rapid response.
BR, Alexey Lukyanov
This issue is now resolved in the latest service release for NetAdvantage for Silverlight 2010 Vol. 3, build 10.3.20103.2159. This service release is available under your account at the Infragistics Website. To download the service release, log in to ‘My IG’ and select ‘Keys & Downloads’. Select the NetAdvantage tab and then click on the product name. The available service releases should now be listed on the page underneath the tab control.Please let me know if you have any further questions or concerns about this matter.