memory (1 Viewer)

sarahb845

Registered User.
Local time
Today, 15:52
Joined
Jun 19, 2002
Messages
43
I am almost completely finished with my database, but I've been hit with an "Out of Memory" run-time error. The error occurs for only 1 report. I can do anything else in the db, except run this report.

I have tried all of the following:
1) Shut down and restarted computer.
2) Compacted & Repaired db: both front-end and back-end.
3) Ran the Analyze Performance for the report and the queries that run it.
4) Imported all tables, queries, forms, reports, modules, macros, menus, etc. into a blank database.

The fe db size before compacting was 26MB (little!!) and went down to 1.8MB. The be db size before compacting was 3.2MB and went down to 2.2MB. They are both located on the C:\ drive on my pc, not on a network. My HD capacity is 9.29GB, with 8.4GB still available. I have 128MB RAM, with 75% still available. File system and Virtual memory are both 32-bit.


ARGGGGG! This is driving me crazy! And, of course, this is the most important report to the user.

Help! Anyone....
sarah
 

ElsVanMiert

Registered User.
Local time
Today, 23:52
Joined
Dec 14, 2000
Messages
152
List of solutions:

This is a wonderful article I found at www.unsoftwareag.com:

ACCESS ONLINE ENCYCLOPEDIA Article Code: G3

Why insufficient memory ?
Description


You can have installed lots of RAM (128 MB and more) on your machine but nethertheless ACCESS crashed after a short period of time indicating that you do not have enough memory to display something. This problem is very frequent during the development phase as you often have to change into design view of forms, reports and modules.
In general you need to reboot your computer to be able to continue. Upgrading your RAM to 256 MB (and more) does not help.
If you check the "Free ressources" window (Windows System or ACCESS Information window) you see between 5 % and 50 % .
Sometimes you will see a system alert with "Memory Running Low" before the crash.
This crash happens on different computers at different times: On Computer 1 ACCESS will crash as soon as the ressources drop under 50%, whereas Computer B will work with less than 10%.

Explanation Part 1


The RAM is divided in different areas that hold different system information. In the so-called GDI-HEAP information about the open windows are stored (Position, Status, Size, Handle...) The size of the GDI-HEAP is limited to 64kB - independantly from the total RAM installed on your machine. Once the GDI-HEAP is saturated the system (or certain programs) will crash.

Explanation Part 2

As soon as you close a window, the occupied area in the GDI-HEAP should be released. Unfortunately, this does not work properly with ACCESS neither on closing a single database object (Form, Report, Module...) nor on closing ACCESS.
Explanation Part 3


As soon as you ope any VBA module (globales or Form/Report class module) all modules of the application are opened, each in a single window. In any medium sized application it can easily happen that 100 windows are opened instantly. This moment leads quite often to a crash because the GDI HEAP is saturated.
Solutions

There are several workarounds, you should opt for a combination:
Limit the number of forms, reports and modules.
Delete all unused database objects
Limit the number of background graphics and tab controls
Distribute your database objects on different libraries
Recreate your database file regularly and import the objects
Activate the VB password and only one module window will be opened at a time
(ATTENTION: removing the VB password again might become difficult).
Do not close forms that you permanently need but make them invisible. See Article F46 for details.
 

Users who are viewing this thread

Top Bottom