Full Version: Why Does Access Shut Down Whenever I Try To Use A Form To Enter
UtterAccess Forums > Microsoft® Access > Access Forms
deek
I'm using a database interface that was created in Access 97; but recently my computer was upgraded to Access 2000. Ever since the upgrade, the interface doesn't work so well.
There is one particular quirk that is seriously hindering performance. I have a form which I use to enter records into a table. I can manually enter records into the table itself with no problem; but when I try to enter a new record on the form, a window pops up containing the message:
"Microsoft Access has encountered a problem and needs to close. We are sorry for the inconvenience.
The information you were working on might be lost. Microsoft Access can try to compact and repair your open database.
(check box, checked) Repair my open database and restart Microsoft Access
Please tell Microsoft about this problem.
We have created an error report that you can send to help us improve Microsoft Access. We will treat this report as confidential and anonymous.
To see what data this error report contains, CLICK HERE.
Send Error Report / Don't Send"
Ocan't seem to get anywhere with this situation; and the problem doesn't seem to make any sense. I figure it must be related to the upgrade to Access 2000, since it never happened before the upgrade.
Can anybody shed some light on this for me? Thanks
deek
MicroE
Try converting the database to 2000, and then compile the VBA code..
deek
The database has already been converted to 2000, although I was not aware of that when I posted earlier.
Is for the compiling of the VB code- how do I do that?
MicroE
Close an open instances of Access.
From the command line, type msaccess.exe /decompile.
Access opens up. Open the database you want to decompile. Depending on the version of Access you are using, you may or may not see a message about VBA code. If you do see the message, just ignore it.
Open up any module. Select the Compile All Modules and Save All Modules menu items.
Close your database.
Close Access.
deek
I typed msaccess.exe/decompile in the command line, and Access opened up. Then I opened the database I wanted to compile, and opened a specific module; but I can't seem to locate any menus that contain "Compile All Modules" or "Save All Modules". I've looked in all of the pull-down menus, so I'm not sure where these menu items should be. Can you please specify where these options exist? Thanks
MicroE
Under Debug from the Menu Bar in Visual Basic Editor.
deek
The Debug pull-down list is there; but under it there is no entry for "Compile All Modules" or "Save All Modules".
There is one item on the list that says "Compile Misc Project Management", and then there are the typical "Step Into", "Run to Cursor", "Add Watch", "Quick Watch", "Toggle Breakpoints", and "Clear All Breakpoints", and a few unavailable menu items. So I'm not clear on how to get the effect of "Compile All Modules" and "Save All Modules", which seem to be only available in Aceess 97, but not in 2000.
deek
I just realized that in the version of Access that I'm using, the command DEBUG-COMPILE <Project Name> replaces the commands DEBUG-COMPILE All Modules and DEBUG-COMPILE Save All Modules.
o that means that I have done the compiling as you instructed the other day; yet the data-entry problem still exists. Do you know where I should go from here?
MicroE
Here are some options:
- Try opening the form in design view, File > Save As the form to a different name. Use that new form and se if it gives you problems. If it seems to work than delete the original form, and rename the new form to the name of the original form.
2 – Create a new Access 2000 database. Import all the objects form the existing database into the new one. File > Get External Data > Import. Test the new database – if everything works, rename and use it in place of the one with the corrupted form.
3 – Delete the corrupted form. Import the form from a previous back up copy of the database (one in which the form was working).
4 – Complete recreate the corrupted form from scratch.
NOTE: Before attempting any of these steps – make sure to back up your files first.
Garfieldm842
Try
These commands can be run from the immediate window:
saveastext acForm,"frmName", "D:\frm.txt"
Change the name of your existing form before you execute this next line:
loadfromtext acForm, "frmName","D:\frm.txt"
This will save the form as text and then you can load it back from text. This can sometimes help correct problems like the one you are having.
deek
i put in the command:
aveastext acForm,"frmProjectMgmt", "c:\frm.txt"
into the immediate window; but i keep getting an error message saying: "Run-time error 2220. Database can't open the file 'c:\frm.txt'
do you know what that means?
Garfieldm842
I am not sure what is causing your problem. I have tried to make the command break on my own machine, by passing in a mispelled form name (broke but not the same error as you) and by creating a text document with the same name and then exporting (no error occured when a file with the same name already existed).
It may have something to do with your database or computer security settings. Can you create a .txt file on your C:\?
This is a "lo-fi" version of UA. To view the full version with more information, formatting and images, please click here.