New
#1
Batch file & XCopy
I hope this is the correct forum??
I have a small network with 2 XPs and 1 Win7. The Win 7 PC recently replaced on older XP PC. I have been backing up accounting data from one XP to another XP using a DOS batch file that uses the XCopy command and this has been working fine for several years. An accounting package that resides on the Win 7 PC can access the data on the XP with no problem.
I moved the batch file to the Win7 PC and it fails with "Invalid drive specification".
The data on the XP PC that needs to be copied resides in "c:\accounting\quickbooks" and "c:\accounting\peachtree". On the Win7 PC the "c:\accounting" is mapped as "Z".
If I use the DOS prompt I can do a "Dir Z:\" and it works. I can also run the same xcopy command from the batch file at the DOS prompt and it works fine.
The one xcopy command is:
XCOPY Z:\QuickBooks\*.* c:\Data\Zipped\QuickBooks\ /E /V /C /H /R /Y
Why does the batch file fail??? For some reason it can't "see" the "Z" drive. I also want to run the batch file nightly as a scheduled task.
Thanks