Windows Cannot find '[path/filename]'...

Kinger43

racecar driver
Local time
Today, 16:15
Joined
Aug 17, 2007
Messages
226
I have written a batch file that calls shortcuts to 4 macros in 4 different Access databases. The goal is for this batch file to run every night and update the 4 databases. The problem that I am running into is that for one of the databases it will run the macro completely through and then throw me the error mentioned in the title where the [path/filename] is the shortcut to the macro that it just ran. Doesn't make sense that it will call the macro, open the database, run the macro, close the database (per a Quit statement at the end of the macro), and then say it can't find the shortcut that it just opened. Any help is appreciated.
 
I created a database not too long ago for a customer, and everytime I open my version of her file now on my machine, I get this same type of message. I cannot figure out how to get rid of it. The file opens just fine, but the dialog box always pops up. Is this the same thing that's happening to you? I believe mine might be caused by some compacting operations I did in the past (or lack there of). I can't think of any other reason...
 
You might put a "Do Events" before you close the database. This will force Access to finish the work it's doing before it quits.
 
I'm experiencing the same thing. I have a batch file that opens an Access database and processes a macro. In the middle of processing, the batch file throws the Windows Cannot file J:... file message. The entire time Access is processing. I click Ok, and the batch continues processing. The problem is, this is run on a scheduler and I don't want to have to click anything. I tried the Do Events before closing without success.

I even wrote a function that pauses the script 30 seconds before closing.

It helped, but it's still getting the error 50% of the time... Any help would be GREATLY appreciated. I'm running Access 2007...

Thanks... Paul
 

Users who are viewing this thread

Back
Top Bottom