db keeps getting corrupted

  • Thread starter Thread starter Cheryl B
  • Start date Start date
C

Cheryl B

Access corrupted my database today, so I restored a backup
copy, which worked fine for a few minutes, then also got
corrupted in the same weird way.

Here are some of the symptoms:
When running the form, upon clicking on a text box that
does not have an OnClick event, I get the message "the
expression OnClick you entered as the event property
setting produced the following error: Return without
GoSub."

In design mode, the text box shows an Event Procedure in
the Click event. When I click on the 3 dots, it takes me
to a VBA screen that is missing the Object Browser, some
of the top toolbars, and is just plain not built normally.

In design mode, when I try to see the code behing the
OnClick event on the command button, sometimes it shows an
abnormal VBA screen, and sometimes it just shows an empty
error message box.

When running the form, if I click on the command button, I
get "The instruction at '0x308ca2c2' referenced memory
at '0x00000002'. The memory could not be 'read'." Clicking
on the message box's OK button aborts Access.

Any help will be appreciated.
 
What happens when you issue a Compact and Repair against your database? See
Tools | Database utilities ...
Is your form's textbox fixed? If not, then... Are their more than you using
the database? If so, let us know how many and where your database resides.
If the compact and repair seems to be successful, open the database and try
your form again. If you continue to have problems, then...

Go into the code editor window and issue a Compile against the database?
Does it find one or more coding problems? Check under Tools | References to
ensure you are not missing any needed references. Once you get a good
compile check to see if that has solved the textbox problem. If it doesn't,
it may be necessary to delete the offending textbox and adding it back.
However, if you go this route, after removing the offending textbox check to
make sure you can compile cleanly before creating a new textbox control on
the form. If this recreation does not work, it may be necessary to create a
new form. Forms can get corrupted and unusable even after a compact and
repair.

Try these things first and post back with any results.
 
Cheryl B said:
When running the form, if I click on the command button, I
get "The instruction at '0x308ca2c2' referenced memory
at '0x00000002'. The memory could not be 'read'." Clicking
on the message box's OK button aborts Access.

Now this isn't exactly the same message as you indicate as yours is
"memory could not be 'read'". However it's close enough that this
might be the same problem.

I've personally seen msaccess.exe - Application Error "The instruction
at "0x12345678" referenced memory at "0x90abcdef". The memory could
not be "written" which decompile fixed. Where the eight digit
numbers were different each time I started up the MDB or at random
times when working with the MDB.

(Several months later.) Turns out this problem was almost certainly
caused by some bad RAM up around 891 Mb of a 1024 Mb RAM system.
<sigh> So if you're getting this problem I strongly urge you to use
Memtest86 - A Stand-alone Memory Diagnostic www.memtest86.com. It
worked for me. Among other things this test can be downloaded as an
ISO image which results in a self booting CDR.

There have been comments indicating that memtest86 sometimes shows
problems which don't exist according to some technicians. OTOH I've
run it overnight on some systems and haven't located any problems
which weren't there.

(Several months even later). This problem must have been caused by the
bad RAM as I've never gotten the message since the RAM was removed and
replaced.

Tony

--
Tony Toews, Microsoft Access MVP
Please respond only in the newsgroups so that others can
read the entire thread of messages.
Microsoft Access Links, Hints, Tips & Accounting Systems at
http://www.granite.ab.ca/accsmstr.htm
 
I will definitely run the memtest. In the meantime, I have
gotten around the problem by creating a new, blank db and
importing all the tables, forms, and queries that I need.
The problem has not occurred (knock on wood) in the new db.

thanks for your help.

Cheryl B
-----Original Message-----


Now this isn't exactly the same message as you indicate as yours is
"memory could not be 'read'". However it's close enough that this
might be the same problem.

I've personally seen msaccess.exe - Application Error "The instruction
at "0x12345678" referenced memory at "0x90abcdef". The memory could
not be "written" which decompile fixed. Where the eight digit
numbers were different each time I started up the MDB or at random
times when working with the MDB.

(Several months later.) Turns out this problem was almost certainly
caused by some bad RAM up around 891 Mb of a 1024 Mb RAM system.
<sigh> So if you're getting this problem I strongly urge you to use
Memtest86 - A Stand-alone Memory Diagnostic
www.memtest86.com. It
 
Compact and Repair had no effect on the problem. Compiling
gave the error "The instruction at "0x308ca2c2" referenced
memory at "0x00000002". The memory could not be "read".
Deleting the textbox did not create any improvement.
Deleting and re-adding the command button did not cause
any improvement.

However, I have gotten around the problem by creating a
new, blank db and importing all the tables, forms, and
queries that I need. The problem has not occurred (knock
on wood) in the new db.

thanks for your help.

Cheryl B
 
I will definitely run the memtest. In the meantime, I have
gotten around the problem by creating a new, blank db and
importing all the tables, forms, and queries that I need.
The problem has not occurred (knock on wood) in the new db.

Yeah, that worked for me for a day or two.

Tony

--
Tony Toews, Microsoft Access MVP
Please respond only in the newsgroups so that others can
read the entire thread of messages.
Microsoft Access Links, Hints, Tips & Accounting Systems at
http://www.granite.ab.ca/accsmstr.htm
 
Back
Top