We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date
close icon

Memory leaks

When I place a grid on a form and look at it with a memory profiler, weird things seem to be going on. On each MouseMove over the grid, the undisposed instance count for types like GridStyleInfoStore goes up ... and never comes down. Is this avoidable? Dirk Puis

4 Replies

AD Administrator Syncfusion Team August 17, 2004 11:36 AM UTC

The styles will get disposed eventually. The default GridVolatileData implementation has a collection of WeakReferences to the GridStyleInfo objects it creates. Once garbage collection collects these instances they will get disposed. (There will be a huge difference between release and debug version when they are collected). You have the option to provide your own GridVolatileData implementation. For example, the GridPerf example implements a different solution when you don''t need QueryCellStyleInfo callbacks. Attached find also a modified VirtualGrid sample that I creatd recently and uses a modified GridNonVirtualVolatileData class. Just in case you are interested in investing this option further ... In that sample QueryCellInfo is only called once for a cell. Then it gets stored in the same style cache that we used in GridNonVirtualVolatileData class and after a cell was initialized the QueryCellInfo event will not be raised again for that cell. Stefan OneTimeOnlyQueryCellInfo_140.zip


DP Dirk Puis August 18, 2004 08:05 AM UTC

ok, seems like I was looking at the wrong column in my profiler. The manual mentioned a caveat. Thanks for the help. Dirk


DB David Bosak January 25, 2005 04:16 AM UTC

I cannot get this attachment. Please give me another link. Thanks!


AD Administrator Syncfusion Team January 25, 2005 04:54 AM UTC

You can try this link. http://64.78.52.104/support/user/uploads/OneTimeOnlyQueryCellInfo_140.zip Or, if you have 3.0.1.0 installed, you can get it at: \Syncfusion\Essential Suite\3.0.1.0\Windows\Grid.Windows\Samples\Performance\OneTimeOnlyQueryCellInfo

Loader.
Live Chat Icon For mobile
Up arrow icon