Top 3 Products & Services
Dated: Mar. 21, 2005
This is a tutorial to create a simple yet very handy utility with a batch file to back up files from many different parts of your computer and even your registry.
First let's take a look at the code and then we'll explain each part.
Let's talk about what the code is doing at the moment and then we'll go into what each part does individually.
There are 5 things that this script is backing up meaning basically copying from one place and pasting it in the other.
Every programmer, or scripting person has thewier own way of working so in this case you'll see mine. It may not be the most efficient way of putting this code down but it makes it easy for me to understand the way I have it here. Once you the readers understand how and what is happening you may want to reduce this code and still make it work perfectly.
First we have
MD %homedrive%\BackUPS\Address_Book\. This means you are commanding your computer to "Make Directory" in your boot drive which is
"C:\" in most cases. And then it'll create a
"BackUPS" directory and
"Address_Book" directory inside that. By now, you must have realized that I'm trying to back up my Windows Address Book. Notice how
%homedrive% is used as a substitute for
Next we used
COPY /y %homedrive%\Progra~1\Outloo~1\WAB.exe %homedrive%\BackUPS\Address_Book\. Let me warn you, this is not the optimum way to putting this command down. But it will help you tweak it correctly for optimum efficiency. What this command is doing is that it's copying a
"WAB.exe" file from Outlook folder inside Program Files Folder and pasting it in this new backup folder we created. Notice how
"/y" is used after
COPY. This is called a modifier and helps to suppress prompting to confirm you want to overwrite an existing destination file.
Now that you've gotten free know-how on this topic, try to grow your skills even faster with online video training. Then finally, put these skills to the test and make a name for yourself by offering these skills to others by becoming a freelancer. There are literally 2000+ new projects that are posted every single freakin' day, no lie!