DOS and Batch Files


DOS and batch files have been around for a very long time and are still very useful. There are some very good sites that list all the DOS and batch file commands among them are...

Computer Hope
Microsoft Technet
Ron van der Woude's Scripting Pages

Various examples of batch files are all over the internet but some of the best are in some of the newsgroups and sites

Timo Salmi's Script Tricks

These pages aren't anywhere that comprehensive but instead aims to offer some tips, tricks, techniques for batch files. A sort of batch files by example.

Escape character - using <, >, |, &, % and ^
Testing for empty strings, spaces and the length of a string - user input, DEFINE
SET: Odd behavior in loops, not updating - SETLOCAL EnableDelayedExpansion
SET: Scope and life of variables - SETLOCAL, ENDLOCAL

This page created 21st December 2011, last modified 31st December, 2011