Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

"error accessing file."

Status
Not open for further replies.

ibethea

MIS
Feb 8, 2002
20
US
After importing an form into a .adp I try to open the form
and I get the message "error accessing file." "Network
connection may have been lost." I do not get this with
every import. It is possible that the imported for may
have been related to a linked table. The error happens in
design mode of the form code modules. I am in the process
of converting the applicaiton from DAO to ADO. I do not
run the form before I try to make the code changes. Also,
I deleted one of the forms that generated the problem.
However, the code in the "code view" related to the form
did not go away. It still has a reference to the deleted
form. I also get the same error message when I double
click on the form reference, then the code shows up for
the delete form. I have run a detect/repair. This
procedure had no impact on the problem.

PS
The network connection is intact.
.

 
I have had similar errors happen when importing forms and naming them the same as previously deleted forms. Try compacting the database after each deletion prior to importing new forms and see if it helps.

I hope this gets you a little closer,

BAKEMAN [pimp]
 
iBeth,

Bakeman was almost correct.

Whenever you import a form/with code or a code module, the very next step you must do is open the Form and then the code window. Then select Compile the db.

THIS IS A MUST!!! (You must compile the Database next)

Otherwise, when you do something else or close and exit Access, your code is gone. And you must get a clean compile!


You should also do this if you make a copy inside your database of a form, or rename a form.
This error showed up in Access 2000. Was never an issue in Access97. Drove me batty for weeks, until I realized it had nothing to do with the 'Network'.

Hope This Helps,
Hap [2thumbsup]



Access Developer [pc] - [americanflag]
Specializing in Access based Add-on Solutions for the Developer
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top