Click here to Skip to main content
15,898,035 members
Home / Discussions / Windows Forms
   

Windows Forms

 
QuestionSmall size application Pin
FaisalMoon21-Dec-09 20:07
FaisalMoon21-Dec-09 20:07 
AnswerRe: Small size application Pin
Roger Wright21-Dec-09 20:21
professionalRoger Wright21-Dec-09 20:21 
GeneralRe: Small size application Pin
FaisalMoon21-Dec-09 20:40
FaisalMoon21-Dec-09 20:40 
GeneralRe: Small size application Pin
Eddy Vluggen22-Dec-09 7:09
professionalEddy Vluggen22-Dec-09 7:09 
GeneralRe: Small size application Pin
FaisalMoon22-Dec-09 19:39
FaisalMoon22-Dec-09 19:39 
GeneralRe: Small size application Pin
Eddy Vluggen23-Dec-09 5:04
professionalEddy Vluggen23-Dec-09 5:04 
QuestionWindows Form with TableLayoutPanel is changing its Controls position when is shown in mdiParent Form. How to Resolve this Issue? Pin
Nouman_gcu21-Dec-09 1:20
Nouman_gcu21-Dec-09 1:20 
QuestionWindows Forms Memory Usage... Pin
1.21 Gigawatts20-Dec-09 5:05
1.21 Gigawatts20-Dec-09 5:05 
Hi peeps!

I've got a Windows Forms application that opens another Windows Form as a dialog (IE ShowDialog).
When the dialog is closed I call Dispose on the object, set it to null, and then call GC.Collect().


However when looking at the memory usage in the Windows Task Manager, the memory usage never goes back down to what it started at initially.

I know that you can't determine when garbage collection is done, but I thought that was the purpose of the GC.Collect() method.


For example it starts off at 6,360k; if I open and close the dialog say 10 times, the memory usage goes up to 7,104k
I leave it running in minimized state for half an hour and the memory usage is 7,080k.

(Interestingly if I maximise it, then memory usage goes up by varying amounts, and stays there.
Minimize then maximize and it does the same again. Keep doing this and it stops increasing after about 100k of extra memory increase, but the memory never goes down to what it was before I did the 'jiggle').


I've run FXCop on the assembly to see if I hadn't implemented any Dispose functionality correctly, but it didn't highlight anything.

There's nothing in the entire application that is accessing files or databases - just what I would call standard .net stuff.


Am I overlooking something, am I worried too much, or am I just being stupid?

I've done various searching and reading on google, but still seeing this effect.



Vague answers are fine - it's a fairly vague question Wink | ;)


TIA Thumbs Up | :thumbsup:
Smile | :)


"If you can't explain it simply, you don't understand it well enough" ~ Albert Einstein
"If you think it's expensive to hire a professional to do the job, wait until you hire an amateur." ~ Paul Neal "Red" Adair

Now reading: 'The Third Reich', by Michael Burleigh

AnswerRe: Windows Forms Memory Usage... Pin
Luc Pattyn20-Dec-09 5:10
sitebuilderLuc Pattyn20-Dec-09 5:10 
GeneralRe: Windows Forms Memory Usage... Pin
1.21 Gigawatts20-Dec-09 5:11
1.21 Gigawatts20-Dec-09 5:11 
GeneralRe: Windows Forms Memory Usage... Pin
Luc Pattyn20-Dec-09 5:28
sitebuilderLuc Pattyn20-Dec-09 5:28 
GeneralRe: Windows Forms Memory Usage... Pin
1.21 Gigawatts20-Dec-09 5:48
1.21 Gigawatts20-Dec-09 5:48 
GeneralRe: Windows Forms Memory Usage... Pin
Luc Pattyn20-Dec-09 6:27
sitebuilderLuc Pattyn20-Dec-09 6:27 
AnswerRe: Windows Forms Memory Usage... Pin
Dave Kreskowiak20-Dec-09 7:57
mveDave Kreskowiak20-Dec-09 7:57 
GeneralRe: Windows Forms Memory Usage... Pin
1.21 Gigawatts20-Dec-09 19:46
1.21 Gigawatts20-Dec-09 19:46 
GeneralRe: Windows Forms Memory Usage... Pin
Roger Wright21-Dec-09 20:29
professionalRoger Wright21-Dec-09 20:29 
QuestionDatagridview inside a datagridview combobox control. Pin
arj_agt17-Dec-09 2:10
arj_agt17-Dec-09 2:10 
AnswerRe: Datagridview inside a datagridview combobox control. Pin
Mycroft Holmes17-Dec-09 4:01
professionalMycroft Holmes17-Dec-09 4:01 
GeneralRe: Datagridview inside a datagridview combobox control. Pin
arj_agt17-Dec-09 4:34
arj_agt17-Dec-09 4:34 
GeneralRe: Datagridview inside a datagridview combobox control. Pin
Mycroft Holmes17-Dec-09 12:02
professionalMycroft Holmes17-Dec-09 12:02 
GeneralRe: Datagridview inside a datagridview combobox control. Pin
arj_agt17-Dec-09 15:39
arj_agt17-Dec-09 15:39 
GeneralRe: Datagridview inside a datagridview combobox control. Pin
arj_agt24-Dec-09 2:27
arj_agt24-Dec-09 2:27 
QuestionFluid Layout By Custom Polygon Shapes Pin
Som Shekhar15-Dec-09 18:36
Som Shekhar15-Dec-09 18:36 
AnswerRe: Fluid Layout By Custom Polygon Shapes - [REPOST] Pin
Richard MacCutchan15-Dec-09 23:27
mveRichard MacCutchan15-Dec-09 23:27 
GeneralRe: Fluid Layout By Custom Polygon Shapes - [REPOST] Pin
Som Shekhar15-Dec-09 23:28
Som Shekhar15-Dec-09 23:28 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.