Presentation is loading. Please wait.

Presentation is loading. Please wait.

DOS Shell Essential Commands ntcmds.chm HTML version.

Similar presentations


Presentation on theme: "DOS Shell Essential Commands ntcmds.chm HTML version."— Presentation transcript:

1 DOS Shell Essential Commands ntcmds.chm HTML version

2 Help 3 ways to get help: ntcmds.chm help command command /? DOS prompt

3 Syntax Commands are case insensitive. cmd1 & cmd2 cmd1 && cmd2 cmd1 || cmd2 DOS prompt

4 Directories & Files cddir%PATH% mdrd copyxcopy delmoveren printtype DOS prompt

5 xcopy source destination /s xcopy source destination /t DOS prompt

6 System cmddoskeyset morefindsort datetimehelp clsprompt tasklisttaskkill DOS prompt

7 cmd /k fvars.bat doskey d  dir /w /p set set path  d:\phys\Salford; %path% DOS prompt

8 控制碼 控制碼的 數值同義字 描述 STDIN0 鍵盤輸入 STDOUT1 輸出至 [ 命令提示 字元 ] 視窗 STDERR2 輸出 [ 命令提示字 元 ] 視窗時發生錯 誤 UNDEFINED3-9 應用程式分別定義 這些控制碼而且每 一個工具有特定的 控制碼。 DOS prompt

9 Redirection <|<| >>> >&<& DOS prompt dir /w | sort /r | more dir > file.txt 2 >&1 find “phys” file.txt

10 Variables Variables are not case sensitive. Substitution is not recursive. set %var  value%var% Batch file arguments: %1 … %9 %0  name of batch file %*  entire argument list

11 Shell Programming echocallexit pauseforgoto ifremshift setlocalendlocal DOS prompt

12 for %f in (*.txt) do type %f for /L %f in (1,2,5) do md Chap_%f for /L %d in (9,-2,6) do md Chap_%d && cd Chap_%d for /R d:\ %f in (*.exe) do @echo %f if exist in.dat guess.exe  in.dat else guess.exe if /i str1   str2 exit DOS prompt


Download ppt "DOS Shell Essential Commands ntcmds.chm HTML version."

Similar presentations


Ads by Google