Below is a batch file I created to copy all the files from a program called A5V5. This batch file works to copy the files to two different drives What I want to do is if the J: Directory is not availble (This is a flash drive) that it will copy to the E:\ directory which is a second HDD and not leave a "The system cannot find the drive specified" when the flash drive is not inserted.
@echo off
cd c:\
cd program files (x86)
cd A5V5
cd Ranch Mobile, Inc
Copy *.* "E:\Ranch Mobile" (This is a second hard drive for backup files only)
Copy *.* "J:\Ranch Mobile" (This is a Flash drive that is not always inserted)
Pause
Thanks for any help. I like the way batch files work and I can do these simple ones but when it comes to doing the more complicated ones I am at a total loss.
@echo off
cd c:\
cd program files (x86)
cd A5V5
cd Ranch Mobile, Inc
Copy *.* "E:\Ranch Mobile" (This is a second hard drive for backup files only)
Copy *.* "J:\Ranch Mobile" (This is a Flash drive that is not always inserted)
Pause
Thanks for any help. I like the way batch files work and I can do these simple ones but when it comes to doing the more complicated ones I am at a total loss.
My Computer
- Computer Manufacturer/Model Number
- Custom Built
- OS
- Windows 7 Home Premium 64 bit
- CPU
- AMD Phenom X4 9750 2.4Ghz 4MB OEM CPU
- Motherboard
- MSI 785GTM-E45 AMD 785G Socket AM2+ Motherboard Model MS-754
- Memory
- 4 GB Patriot Signature 2048MB DDR2 800MHz (2)
- Graphics Card(s)
- ATI Radeon HD4200 On Board
- Sound Card
- Chip integrated by Realtek ALC888S
- Monitor(s) Displays
- Samsung SyncMaster 933
- Hard Drives
- Seagate 500 GB Serial ATA
- PSU
- Power Up LT 400w ATX
- Case
- Diablotek EVO CPA-6170 Mid-Tower
- Cooling
- Zalman Ultra Quiet Cooler CNPS7000V(AL)-I-PWM