I am getting the error "run-time error '70' permission denied" when performing
FileCopy file1, file2
This is due to the fact that file1, which is an Access database, is open.
Is there a way around this? This code is run overnight and obviously some users are leaving the db running. This is not something I can do much about so need to find a work-around.
Any ideas?
pass the path and name of currentdb and new path and db name
could be on the same path/folder but must be different db name, say add a datetime to the backup copy
Open in new window