Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

Memory Leak using MDI Child Forms

Posted on 1998-10-09
6
Medium Priority
?
219 Views
Last Modified: 2008-02-26
I am currently working on a VB5 project that uses about 10 MDI Child forms. During testing we found that as we opened up multiple instances of the same form and other forms, we are losing from 15 - 40 kb of memory per form. After about 3-4 hours of continuous use, the program receives an access violation Exception error. Is there anyway to release all resources allocated to these forms, or at least minimize what they waste?
0
Comment
Question by:mheeg
6 Comments
 
LVL 12

Expert Comment

by:mark2150
ID: 1439052
Use Form.Unload when instance is no longer required...

M
0
 

Author Comment

by:mheeg
ID: 1439053
I am working on an NT 4.0 Workstation using SP3
0
 

Author Comment

by:mheeg
ID: 1439054
We currently use:
            Unload Me

And then in the Unload Event:
            Set frmWhatever = Nothing

Is this pretty much what you had in mind?
0
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 

Author Comment

by:mheeg
ID: 1439055
We currently use:
            Unload Me

And then in the Unload Event:
            Set frmWhatever = Nothing

Is this pretty much what you had in mind?

0
 
LVL 14

Accepted Solution

by:
waty earned 300 total points
ID: 1439056
You can download the following file, it gives you indication on how optimize your application to avoid memory leaks, increase the speed...

http://www.geocities.com/ResearchTriangle/6311/article002.htm
0
 

Expert Comment

by:hess
ID: 3691114
Did you ever find a better answer for this? I'm having the same problem and really need to fix it.
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article describes some techniques which will make your VBA or Visual Basic Classic code easier to understand and maintain, whether by you, your replacement, or another Experts-Exchange expert.
You can of course define an array to hold data that is of a particular type like an array of Strings to hold customer names or an array of Doubles to hold customer sales, but what do you do if you want to coordinate that data? This article describes…
Get people started with the process of using Access VBA to control Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…
Suggested Courses

824 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question