Batch File Tips for DOS/Windows

Current .bat File Directory (Ends with \): %~dp0

Don’t display command: @

Don’t display all commands and outputs: @ECHO OFF

Comment line: REM

Wait for enter key: PAUSE

Parameters:

%0 is the program name as it was called,
%1 is the first command line parameter,
%2 is the second command line parameter,
and so on till %9.

Advertisements