Users have shortcut on their desktop that points to a simple bat file (see below)
The batch file creates a new folder on user's hard drive, if needed, then copies an Access front-end file (.mdb) from a network folder down to the hard drive.
I was using xcopy so that it only copied the file, IF I had made a change.
I recently had to change to using UNC paths and now that XCopy doesn't seem to work. I can only get it to work for the users with a straight copy. XCopy works fine on my PC. Just before the copy is executed there is a message that "UNC Paths are not supported"
Am I doing something wrong? Is there a delay with the xcopy on the network that I need to "pause" or something?
Any help is appreciated.
TJ
---------
@Echo Off
Rem Check for local copy of XYZ.mdb - if not found, create directory and copy file.
if not exist "C:\TEST1\XYZ.mdb" mkdir "C:\TEST1"
if not exist "C:\TEST1\XYZ.mdb" copy "\\PBNTFS99\SHR_access\CLO\XYZ.mdb" "C:\TEST1\XYZ.mdb" /y
Rem xcopy the latest version from server to hard drive
xcopy "\\PBNTFS99\SHR_access\CLO\XYZ.mdb" "C:\TEST1\XYZ.mdb" /y /d
start /max /HIGH C:\TEST1\XYZ.mdb
-------
I had to change the xcopy line to the following to get it to work:
copy "\\PBNTFS99\SHR_access\CLO\XYZ.mdb" "C:\TEST1\XYZ.mdb" /y