Batch file newbie help

Associate
Joined
18 Oct 2002
Posts
797
Location
Manchester
I have been asked to look at creating batch files to use with Remote client.
However I dont have the faintest idea of how to create batch files, is there an online resource or other tutorial that anyone could recommend?

Thanks for looking in
:)
 
Create a text document and rename it to test.bat.
Heypresto you have created a batch file.

A batch file essentially allows you to double click on a file and run dos commands within that file.

Just go Start->run type 'cmd' and then hit enter. In the black dos box just do 'help'
to show most of the commands available and then type one of the commands and /?
hence if i type 'copy /?' it will tell me what the command does and what parameters you can pass it. I am sure a google for 'batch files' will poduce a load of useful resources.
A simple example of a batch file is below:
If I wanted to backup a file called test.txt from the C drive to the D drive I could do the following.
Create a file on C called Backup.bat, right click edit
Then enter this text and save file
COPY "C:\test.txt" "D:\test.txt"
Then you could automate this via windows scheduled tasks so it ran every day.
 
Last edited:
Back
Top Bottom