How to use Dir Command In Windows Server 2008
This article shows how to use Dir command in Windows Server 2008 operating system and also explains the syntax related with it.
Dir command in Windows Server 2008 operating system is used to show the list of directory's files and subdirectories. This command is also used to show total number of files and directories listed, their size and free space remaining on the disk. Syntax for Dir command is given below.
dir [<Drive>: ] [<Path>] [<Filename>] [ . . . ] [/p] [/q] [/w] [/d] [/a [ [ : ]<Attributes>] ] [ /o [ [ : ]<SortOrder>] ] [/t [ [ : ]<TimeField>] ] [/s] [/b] [/l] [/n] [/x] [/c] [/4]
Parameters For Dir
||Defines the drive and directory for which you want to see a listing.
||Describes a particular file or group of files for which you want to see a listing.
||Shows one screen of the listing at a time.
||Shows file ownership information.
||Shows the listing in wide format.
||Shows the listing in the same format as /w.
||Shows only the names of those directories and files with the attributes that user specify.
||Used to sort the output according to SortOrder.
||Defines which time field to display or use for sorting.
||Lists every occurrence of the specified file name within the specified directory and all subdirectories.
||Shows a bare list of directories and files, with no additional information.
||Shows unsorted directory names and file names in lowercase.
||Shows a long list format with file names on the far right of the screen.
||Shows the short names generated for non-8dot3 file names.
||Shows the thousand separator in file sizes.
||Shows years in four-digit format.
||Shows help at the command prompt.
Ask Your Question
Got a programming related question? You may want to post your question here
Programming Answers here