Visual Basic - Out of memory

A

Alp

Hi Experts,

I have been getting this message quite often recently on one PC when I
attempt to see the code. I do remember seeing an article about it but just
can't seem to find it now. Any help, advice, pointers would highly be
appreciated.

Access 2000 (9.0.2720) / W98 SE / P3 550 / 192MB RAM / 20GB & 80GB(ATA IDE
RAID) HDDs

The work is on the raid drive and I have no problems accessing it. It also
looks like something is hogging the system (might be just a hitch).

Thanks in advance.

Alp
 
B

Brendan Reynolds

When you open the VBA editor in Access 2000 (I can't say for sure whether
this behaviour changed in later versions) it will attempt to open all code
windows that were open the last time you saved from within the VBA editor.
You may see only one open code window, but there may be many unseen open
code windows 'behind' the visible window. Eventually, there can be so many
open windows that your system runs out of memory attempting to open them
all.

If you can't get into the code at all, create a new, empty MDB and copy all
of the objects from the old one.

Once you can get into the code, to prevent the problem happening again, get
into the habit of closing all unnecessary code windows and forcing a save
before closing the VBA editor. Saving within the VBA editor will have no
effect unless something has actually changed since the last save, so to
force a save, make some innocuous change, such as putting in a blank line
and then backspacing it out again.

It sounds like a chore, but believe me, it soon becomes a habit that you do
without even thinking about it! :)


--
Brendan Reynolds (MVP)
http://brenreyn.blogspot.com

The spammers and script-kiddies have succeeded in making it impossible for
me to use a real e-mail address in public newsgroups. E-mail replies to
this post will be deleted without being read. Any e-mail claiming to be
from brenreyn at indigo dot ie that is not digitally signed by me with a
GlobalSign digital certificate is a forgery and should be deleted without
being read. Follow-up questions should in general be posted to the
newsgroup, but if you have a good reason to send me e-mail, you'll find
a useable e-mail address at the URL above.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top