I'm helping someone solve an Access 2007 problem. They have a macro that deletes the destination file it's exporting to and I can't figure out why.
Some things I've tried:
1. Saving and exporting the database as an Access 2000 database.
2. Exported the macro to see the VBA code and there is no "kill" statement that would delete the file.
3. Gave trusted permissions to the database because when I originally ran it (and the owner of the database ran it) got a 2950 error.
Steps of the problem:
1. Double click the macro
2. Pop-up states: "The Microsoft Office Access database engine could not find the object 'DEMOFile.txt'. Make sure the object exists and that you spell its name and the path name correctly."
3. Click "OK"
4. Action Failed pop-up: Error Number 2950 (which I don't understand if it's been made trusted).
5. Click "Stop All Macros"
The file that the data is supposed to export to is deleted. It's not in the Recycle Bin, it's just gone.
The Macro Design View:
Action: TransferText
Arguments: Export Fixed Width, QryDEMOFile Export Specification, qryDEMOFile, C:\VALIC\DEMOFile.txt, No, ,
Transfer Type: Export Fixed Width (also fails with delimited)
Specification name, table name, file name are all correct
Has Field Names: No
HTML Table Name and Code Page are blank