Monday, December 20, 2010
【 Weak current College 】 DOS command in Visual FoxPro (1)
To note in DOS, the letter of the command name is not case sensitive.
A .Dir
The command above already mentioned, it is used to list the name of a directory and subdirectory names. The aforementioned input directly a carriage return after the dir, which lists all the current directory and subdirectory names the file name. In fact, it is still a lot of formats, for example in the following one.
1.Dir*.*
This command actually and dir directly after the carriage return is the same.
2.Diraaa\*.exe
Lists the current directory of all aaa subdirectory is exe file name extension.
3.Dirc:dos\*.*
Lists the c drive root directory in a subdirectory under dos and all of the file name of the subdirectory names.
4.Dir/p
Lists all the current directory in the file name and the name of a subdirectory. Row full screen will pause, press any key to continue listing the next screen.
5.Dirc:windows/p
Lists the c disk root directory in the windows subdirectory of the file and subdirectory names. Row full screen will pause, press any key to continue listing the next screen.
Well, we can see, the dir command is composed of three parts: 1. Dir command keyword; 2. A path or a file name, file name, you can use a wildcard character; 3. Some like the/p option. Which command keyword is necessary, the other two being optional, all your needs. If the second is a path, then the dir command lists all the path of the file and subdirectory names. As the case may be. If the second item is a file name, file name contains a path, the dir command lists the path in the file name of the file, as in example 1, example 2 and 3 patients.
The third piece of content, here are several simple column.
1./p
This option enables the dir command column after a full screen, press any key to continue the column to the next screen. P is the first letter of the pause.
2./w
Usually the dir command lists the file name contains the length, the creation date and other information, and each row has only one file name column. This option enables the dir command only lists the file name and extension, and each row can be displayed five file name. This is called wide display. W is wide.
3./od
First letter o is the first letter of the order, meaning that sort. This option and the following belt o options role is to display the results of dir as a way to typeset sequence.
Here d is the first letter of the date, meaning that lists to a file name and name of the subdirectory is created, the orderings of the row, the earliest created at the front.
4./on
O here is not to say. "N" is the first letter of the name. This option allows dir listed by file name in alphabetical order.
5./og
Here the "g" is the first letter of the group. Its role is to make a subdirectory name dir listed first and then lists the file name.
6./os
The "s" is the first letter size. It enables the output of the dir by file size, the smallest of the top.
7./oe
"E" is the first letter of the extent. It enables the output of the dir file name extension sorted alphabetically.
8./s
The "s" is the search for meaning. It enables the dir command in the file name is specified by the directory and all nested depth look for files in subdirectories of the specified file name, and list the results. When you don't know where a file, use this command is useful. For example:
Dirmyfile.txt/resumes in the current directory and all nested in the current directory of the depth of the search file myfile.txt subdirectory.
Dirmyfile.txt/s from the root directory of the current disc, the depth of nesting in all subdirectories in the search for the file myfile.txt.
Of course, it also can find directory. As long as you enter the directory name. In addition, you can use wildcard characters in the file name, is looking for a batch file.
9./?
There are many options, there's no need to mention them all here. Take a self study options: "/?". This option will make the dir command lists the detailed description of it, we can refer to. In fact, all of the DOS command has this self-study options. If you do not know a DOS command usage, as long as the command name followed by/?
Enter to see its usage instructions.
You are not a can only use one option, you can in a dir command in combination with multiple options, each option is not contradictory. For example: od/dir/p will list all the current directory and subdirectory names and file name and follow the create date first good order, column full screen will pause, press any key to another column to the next screen. But dir/od/os will not at your request, the file name and subdirectory names listed, because by creation date sorting and sorted according to size of two conflicting demands, only one.
The dir command of this three part to one or more spaces.
Labels:
[:]
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment