troubleshooting Question

Memory Usage with DataSets never reduces

Avatar of lostinthegame
lostinthegame asked on
DatabasesProgramming.NET Programming
5 Comments1 Solution470 ViewsLast Modified:
I have a windows form project that includes a dataset.  From my main form, the user can open a "load client" form that contains a datagridview.  When the "load client" form opens, I fill a dataset on the form from my sql ce database and then load the dataset into a datagridview.  The database I'm testing with has 10,000 records, and it causes the memory usage to skyrocket.  My issue is that when the user closes the form, the memory usage doesn't decrease.  When they open the "load client" form again, the memory usage almost doubles again.

The form closes using me.dispose, but it doesn't seem to have an effect on the memory usage.

How can I stop this from happening?  To me, it seems like the dataset fills, but the memory is never emptied, so each time I fill the dataset the memory just keeps increasing.
Join our community to see this answer!
Unlock 1 Answer and 5 Comments.
Start Free Trial
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 5 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros