Cool Disk's

 Helping the Spread of Knowledge & Skill's...

Proud Member of the EyeTweaks Network.TM











Special Thanks to Ours Sponsor's
How to become a sponsor

Batch File's How To:
Batch files allow a lists of commands and/or programs to run once.  A batch file can run commands, delete files, move files, copy files etc. A batch file requires relatively no knowledge of programming and can be done thru DOS commands. 


DOS & Windows Users

DOS Users

Create a basic batch file in DOS follow the below is an example of creating a batch file.

  1. Open DOS command prompt window.
  2. Once at the prompt type: edit testbatch.bat and press enter.
  3. You now be in a blue screen. Type:

    dir c:\windows
    dir c:\windows\system
  4. Now select File,  and exit, when prompted to save choose Yes.  You can also use the keyboard by pressing ALT+F, then pressing X to exit and save changes.
  5. Once back at the prompt type testbatch and enter.  This will start the testbatch.bat file you created and run the script you type in it.  You will first be prompted to press a key Because the first line in your command is pause.  The batch file will list down the files in windows and windows\system directory.

To add more commands to the batch file type edit testbatch.bat.

Microsoft Windows and other users

Window's user's can use a DOS prompt or if your use to Windows you can use a text editor like notepad as long as the file extension ends with .bat instead of .txt.  

  1. Click Start
  2. Click Run
  3. Type "notepad" and enter.
  4. Type the lines below into your file or copy and paste into your notepad file.
    @echo off
    echo Hello Testing batch files
    dir c:\windows
  5. The Click File and click Save, Remember where you  saved the file. Now exit notepad.
  6. To run your batch file Double-click or run the file from your dos prompt or cmd line.  Once it has finished running the script you wrote it will close automatically unless your using a DOS prompt.
Member of the EyeTweaks Network, We just keep on Tweaken!TM All copyrights apply.(C)

Contact Us