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
2715
Ultragrid memory handling
posted

Hi!

I have a question : If i load in a ultragrid a big big datatable (using SetDataBinding) so that it takes about 1gb RAM, and after that i dispose the datatable and bind the grid to another datatable, a much smaller one - why doesn't the grid autmoatically decrease the used ram - it remains as big as for the first datatable. 

Parents
No Data
Reply
  • 469350
    Offline posted

    How are you checking the RAM?

    It's possible that the memory is no longer in use, but it simply has not been garbage-collected, yet.

    You can test that like so:

    GC.Collect();

    GC.WaitForPendingFinalizers();

    GC.Collect();

    If the memory does not get freed up after that, then something is wrong. It is, of course, possible that something in your application is holding on to these objects. But it could also be a bug in the grid. We just fixed a couple of memory leak issues in the grid and those fixes will be available in the January service release.

    Are you doing anything to the grid in the sample you describe here? Are you editing a cell, for example? Or does this happen just by setting the DataSource on the grid, clearing it, and setting it again?

Children