Click here to Skip to main content
15,896,207 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
hi dears,
before i run my applicattion,Task Manager memory is 10,253k but when i run my Application and frmsearch,Task Manager memory changed to 15,253k,
so it's usual when i close frmsearch,memory changed to 10,253k but it's dosn't changed.
thnks
Posted

1 solution

Memory in .net is reclaimed by the garbage collector, for this to reduce your memory it will take time (given you release resources correctly in your application).

If you are worried about the memory footprint try (not recommended unless you know what you are doing as it messes with the frameworks internal memory structures) the following code in your debug application.

C#
GC.Collect(2);
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900