access 2003 keeps crashing with encountered errors

C

Chris

I have been trying to work on a database which I have been inherited in
Access 2003 format and was originallly a dat file. When working on the dat
file I would keep getting the generic error
"Microsoft Access has encountered a problem and needs to close. We are sorry
for the inconvenience"

This error generallly occurs in design mode when trying to save a changed
property on a controls not one in particular. I have run compact and repair.
Imported all the forms, tables etc in to a new file both mdb in 2000 and
2003 reinstalled Office 2003 but still get the error message.

Appreciate any pointers as to what could be going on here. PC works fine and
only having problems with Access. Error message doesn't tell me much just
references msaccess.exe and gives a ever chaging offset

Thanks
Chris
 
A

Allen Browne

First, ensure that the Name AutoCorrect boxes are unchecked under:
Tools | Options | General
Then compact the database to get completely rid of this stuff:
Tools | Database Utilities | Compact
This thing should be named, "Name AutoCorrupt". Details:
http://allenbrowne.com/bug-03.html

Second issue in A2002 and A2003 is to ensure that any subforms have a text
box for the fields named in LinkChildFields. There seems to be a bug
associated with the AccessField data type, and you can avoid the bug by
forcing Access to treat it as a TextBox type object instead. The text box
can be invisible, zero-width, ... it just needs to be present. You may also
need to make a design change to the main form and subform (e.g. renaming a
label) to force Access to re-evaluate this change.

Third, perform a decompile. This is something that is not automatically done
when you rebuild the database (importing into a new one). Decompile a copy
of the database by entering something like this at the command prompt while
Access is not running. It is all one line, and include the quotes:
"c:\Program Files\Microsoft office\office\msaccess.exe" /decompile
"c:\MyPath\MyDatabase.mdb"
Then compact again.
Then check that the code does compile (Debug | Compile, from a code window).
Before taking that step, it may be worth checking you have no spurious
references. If you are not sure which references you need, see:
http://allenbrowne.com/ser-38.html

At this point, you should have a database where the name-autocorrect errors
are gone, the indexes are repaired, the AccessField bug is circumvented,
inconsistencies between the text- and compiled-versions of the code are
fixed, and reference ambiguities are resolved.

If it is still crashing at this stage, are there any subqueries in the
RecordSource of these forms? There are some subqueries that crash JET no
matter what you do.
 
C

ChrisA

Thanks for lots of great info and detail will be trying this later today and
will let you know.
Chris
 
Top