Sometimes you might have thought about copying data from a USB/ PenDrive to your computer automatically just when the device is inserted into your computer. Today, we will be discussing on how you can do so.
Things Required:
A computer with Windows installed, Little Knowledge of MS-DOS Commands.
How to do?
Step 1. Open "Command Prompt" on your computer. Just click on Start menu and type CMD in the 'Search' and press Enter.
Step 2. Type "copy con autocopy.bat" (remove the quotes " ") in the Command Prompt window and press Enter.
Step 3. Type "xcopy i: F:\usbcopy /h /s /c /q /i" (remove the quotes " ") and press Enter.
Step 4. Type "Exit" (remove the quotes " ") and press Enter.
Step 5. Press F6.
Step 6. Now it will create a batch file named autocopy.bat
Step 2. Type "copy con autocopy.bat" (remove the quotes " ") in the Command Prompt window and press Enter.
Step 3. Type "xcopy i: F:\usbcopy /h /s /c /q /i" (remove the quotes " ") and press Enter.
Step 4. Type "Exit" (remove the quotes " ") and press Enter.
Step 5. Press F6.
Step 6. Now it will create a batch file named autocopy.bat
Here,
i: is the drive letter of the USB/Pendrive (Replace it with the drive name for USB on your Computer)
F:\usbcopy is the location where you want to copy the USB's data. (Replace it with the directory/folder where you want to copy the USB's data on your computer)
/h is used to copy the hidden files from the pendrive.
Now, copy the 'autocopy.bat' file and paste it anywhere you want. When someone inserts his/her USB into your computer, open 'autocopy.bat' file. It will automatically copy the data to your computer.
Note: The data in the USB/PenDrive will be copied to F:\usbcopy in my case.
0 comments:
Post a Comment
Write Your Comments!