473,320 Members | 1,969 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

MDI Windows Memory Allocation Grief :-/

Hi,

Hope that someone can shed some light on this.

I've got an MDI application with (for the sake of this discussion) 2 child
forms. Both of these forms inherit from on a common 'Base' form which is
quite 'bulky', in that it contains a potentially large DataGrid and a bunch
of supporting DataSets, DataViews etc.

Also on my MDI Parent form, I have a 'Windows' menu option which has the
MdiList property set to True so that it displays a list of MDI Children.

For the purposes of testing, I have a button on my MDI Parent form to force
a GC.Collect.

OK.
If I run the application, open FormA and load a bunch of data onto the
datagrid, then open FormB load a bunch of data onto his datagrid, then I
select FormA (by clicking on the form) and close it, then close FormB to
return to the empty MDI Parent form. All seems to be well and the GC
retrieves all the available memory.

However, and this is the bit I don't understand, if I repeat the above test,
exactly the same, except that when closing FormA, instead of clicking on it
to select it, I use the 'Windows' menu then when I have closed both forms
and returned to the Parent form, the memory never seems to get released, no
matter how long I wait, or how many GC.Collects I force.

If anyone could give me a hint as to what the difference between these two
methods is I would be a happy bunny!

TIA

Chris.
Jul 21 '05 #1
0 1102

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

5
by: Lionel | last post by:
Hi all, Just wondering exactly how memory is allocated using the new operator? More specifically I am interested in how the memory is calculated for globable variables? I recently stumbled into...
13
by: Michael B Allen | last post by:
Hi, I've tried to write the *simplest* memory allocator possible. I think it would be useful in many cases such as allocating memory on stack as a poor man's garbage collection perhaps. I was...
0
by: Chris Mayers | last post by:
Hi, Hope that someone can shed some light on this. I've got an MDI application with (for the sake of this discussion) 2 child forms. Both of these forms inherit from on a common 'Base' form...
2
by: ravishi | last post by:
Well, this is my first topic at this forum and I'm a newbie on C programming too. I'm coding a little program and I've used some "dynamic arrays" on it. Compiling and running the program on Linux...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
0
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.