1. Lệnh Ping : Cú pháp: Code: ping ip/host [/t][/a][/l][/n]


d er name completion and  Ctrl-F gives  F



tải về 1.67 Mb.
Chế độ xem pdf
trang22/92
Chuyển đổi dữ liệu18.05.2022
Kích1.67 Mb.
#52014
1   ...   18   19   20   21   22   23   24   25   ...   92
Cac lenh co ban trong DOS

d
er name completion and 
Ctrl-F
gives 
F
ile and 
folder name completion. 
These key-strokes will display the first matching path. Thereafter, repeated pressing of the same 
control key will cycle through the list of matching paths. Pressing SHIFT with the control key will 
move through the list backwards. 
/Q Turn echo off 
/S Strip quote characters from the command_line 
/V:ON Enable 
delayed environment variable expansion
  
this allows a FOR loop to specify !variable! instead of 
%variable%
expanding the variable at execution time instead of at input 
time.
/V:OFF Disable delayed environment expansion. 
Environment expansion preference can be set permanently in the 
registry 
HKLM | HKCU \Software\Microsoft\Command Processor\DelayedExpansion 
Set to either 0x1 or 0x0 
/knetdiag /debug
/knetdiag /fix 
The knetdiag switches are undocumented and work in XP only 
they list and (may) fix 
these
 networking issues. 
If /C or /K is specified, then the remainder of the command line is processed as an immediate 
command in the new shell. Multiple commands separated by the command separator '&' or '
&&

are accepted if surrounded by quotes. 
The following logic is used to process quote (") characters: 


1. If all of the following conditions are met, then quote characters on the command line are 
preserved: 
- No /S switch (Strip quotes)
- Exactly two quote characters 
- No 
special
characters between the two quote characters, where 
special
is one of: 
& < >( ) 
@ ^ |
- There are one or more whitespace characters between the the two quote characters 
- The string between the two quote characters is the name of an executable file. 
2. Otherwise, old behavior is to see if the first character is a quote character and if so, strip the 
leading character and remove the last quote character on the command line, preserving any text 
after the last quote character. To negate this behaviour use a double set of quotes "" at the start 
and end of the command line. 
Full Screen 
The key combination 
ALT + ENTER
will switch a CMD window to full screen mode. 
press 
ALT + ENTER
again to return to a normal Window. 
Opening CMD from Windows Explorer 
You can open a new CMD prompt by choosing START, RUN, 
cmd
, OK 
Copy and Paste / QuickEdit 
To simplify the use of cut and paste at the Command Prompt, enable 
QuickEdit
mode as 
follows: 
Activate the control menu at the top left of the current cmd window, go to Properties, Options tab 
and then tick against QuickEdit Mode. Now you can select text with the mouse and hit Enter (or 
right click) to copy it to the clipboard. Paste anywhere using Control+V (or Right Click) or via the 
menu. 
ESC will cancel any selection and return to editing mode. 
When copying between windows, you may need one click to select the window and a second 
click to paste. 
Run multiple instances of CMD.exe 
At the command line or in a batch script 
CMD
will start a new instance of CMD.exe which will 
appear in the same window. The EXIT command will close the second CMD instance and return 
to the previous shell. 
A method of calling one Batch script from another is to run a command like 
CMD /c 
C:\docs\myscript.cmd
The output of CMD can be redirected into a text file. Notice that where CMD /c is used, the EXIT 
command is not required. 
The environment Variable %CMDCMDLINE% will expand into the original command line passed 
to CMD.EXE 
The native version of CMD.exe is always in 
%windir%\system32
, on 64 bit operating systems 
there is also a 32 bit CMD.exe in 
%windir%\SysWOW64
Pausing or stopping a batch script 
Execution of any batch script can be paused by pressing 
CTRL-S
This also works for pausing a single command such as a 
DIR
 listing 
Pressing any key will resume the operation.

tải về 1.67 Mb.

Chia sẻ với bạn bè của bạn:
1   ...   18   19   20   21   22   23   24   25   ...   92




Cơ sở dữ liệu được bảo vệ bởi bản quyền ©hocday.com 2024
được sử dụng cho việc quản lý

    Quê hương