Vertical Bar | can be used in DOS commands
The function is to put the symbol before the process output, after making the sign process input.
The code for this example in Codego.net is as follows:
For example, two commands, "dir/s/b/a" and "find". txt "", the first shows all the files, folders in the current folder, and the second is to find a string containing the character ". txt".
Two commands you can "find all files and folders in the current folder that contain. txt." By using a vertical line connection.
DIR/S/b/a | Find ". txt"
Some situations that require a vertical bar (|):
For example, find a specific string or file or folder
This feature is perfect to be familiar with mastering findstr and for, while the pipe symbol (|) is essential when findstr and for are used simultaneously.
CLIP
Redirects the output of the command-line tool to the Windows Clipboard. This text output can be pasted
to other programs.
Parameter list:
/? Displays this help message.
DIR | Clip places a copy of the current directory list into the Windows clipboard.
CLIP < README. TXT places a copy of the Readme.txt into the Windows clipboard.
What, isn't it cool? Try it!
For example, put the current date on the Clipboard.
Echo%date:~,10%|clip
This article is from the "9515233" blog, please be sure to keep this source http://9525233.blog.51cto.com/9515233/1626957
Vertical Bar | can be used in DOS command usage examples