VB Error Message: Error Accessing File

M

Michael Sims

I am receiving the following error message box:

Microsoft Visual Basic
Error accessing file. Network connection may have been
lost.

I get this error when I try to add a command button in an
Access Form. Please help.
Thanks!

(e-mail address removed)
 
D

Dirk Goldgar

Michael Sims said:
I am receiving the following error message box:

Microsoft Visual Basic
Error accessing file. Network connection may have been
lost.

I get this error when I try to add a command button in an
Access Form. Please help.
Thanks!

If you're using Access 2000, and haven't applied SP3, see this KB
article describing the nasty bug that has probably bitten you:

http://support.microsoft.com/default.aspx?scid=kb;[LN];304548

Office 2000 SP3 fixes the bug, but that won't repair your corrupted
database. You'll have to resort to a backup, or else try importing all
objects to a new database -- some objects probably won't import, and
you'll have to recreate them from scratch. When you do import the
objects, unless you've applied the service pack, it is *crucial* that
you compile and save the project before closing the database.
 
J

Jeff Conrad

Hi,

Are you using Access 2000 without SP3 installed by
chance? Is so read on.

I think you've been stung by a particularly nasty bug in
Access 2000. Sure sign is that dreaded "Network Connection
may have been lost.." messsage. Details about it can be
found here:

http://support.microsoft.com/?id=304548

The corruption in your database may not be recoverable.
You might try importing everything into another database.
I believe this bug is fixed with Service Pack 3, but it
will not *fix* corruption already present. To avoid this
bug you absolutely, positively, have to compile your
database EVERY time you import something.

Also, (from Dirk "Yoda" Goldgar) one other thing you might
try first is decompiling your database -- or rather, a
copy of it. Instructions for how to do this may be found
here:

http://www.mvps.org/access/bugs/bugs0008.htm

and here:

http://www.granite.ab.ca/access/decompile.htm

This was also posted by someone from Microsoft (my next employer):

326605 ACC2000: Issues Fixed in Access 2000 by Office 2000 Service Pack 3
http://support.microsoft.com/?id=326605

304548 ACC2000: Error Message: Error Accessing File. Network Connection May
http://support.microsoft.com/?id=304548

After applying Office 2000 sp3 you are going to need to salvage your
database modules (Standard, Forms/Reports) by saving them out to text
files. Example:

- Open Form/Report in design view and select menu option View > Code
- Select the menu option Edit > Select All (to select vba code)
- Select menu option Edit > Copy
- Paste in Notepad file
- Close VBA window to return to Form/Report
- Within the properties Window of Form/Report change the property "Has
Module" from "Yes" to "No"
(this will delete the code behind the object)
- Save your Form/Report
************* Repeat above steps for each Form/Report that has code
*****************
- For your Standard module just open and copy to text files

- Then import all your objects (within exception of your Modules) to a new
database file
- Copy the code from the above text files into new modules in your new
database
- For the Forms/Reports reverse the steps by opening their VBA modules and
pasting the code from the text files

*******************************
You can also try running decompile switch but the above methods are
normally your only shot..


I hope this helps! If you have additional questions on this topic, please
respond back to this posting.


Regards,

Eric Butts
Microsoft Access
Good luck,
 
J

Jeff Conrad

Whats that you say, Jeff?

Just very, very, very wishful thinking on my part Yoda.
It would be nice to have a job where I don't have to worry about being paid each time I get my
paycheck! And it would be nice to be somewhere with unlimited growth potential as well as being on
the forefront of technology changes.

Don't you think Rita could use an Access Junkie working with her?
That would be great!!!!
:)
"Access Ambassador" possibly??
<vbg>
 
D

Dirk Goldgar

Jeff Conrad said:
Don't you think Rita could use an Access Junkie working with her?
That would be great!!!!
:)
"Access Ambassador" possibly??
<vbg>

Keep on the way you're going, Jeff, you're carving out a niche for
yourself. Although you and Fred Boer may have to duke it out for
"Access Humorist".
 
J

Jeff Conrad

Keep on the way you're going, Jeff, you're carving out a niche for yourself.

Thanks, that's very nice to hear.
Although you and Fred Boer may have to duke it out for "Access Humorist".

Heck I'll even be the "Access Waterboy" at MS if I could work there and be better off than I am
now!!
 

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