                         DOS Commands II



**************************************************************** 
 
                GOTO COMMAND ONLINE DOCUMENTATION 
**************************************************************** 
Directs Windows to a labelled line in a batch program.

GOTO label

  label   Specifies a text string used in the batch program as
          a label.

You type a label on a line by itself, beginning with a colon.
 

**************************************************************** 
 
                IF COMMAND ONLINE DOCUMENTATION 
**************************************************************** 
Performs conditional processing in batch programs.

IF [NOT] ERRORLEVEL number command
IF [NOT] string1==string2 command
IF [NOT] EXIST filename command

  NOT               Specifies that Windows should carry out the
                    command only if the condition is false.
  ERRORLEVEL number Specifies a true condition if the last
                    program run returned an exit code equal to or
                    greater than the number specified.
  command           Specifies the command to carry out if the
                    condition is met.
  string1==string2  Specifies a true condition if the specified
                    text strings match.
  EXIST filename    Specifies a true condition if the specified
                    filename exists.
 

**************************************************************** 
 
                KEYB COMMAND ONLINE DOCUMENTATION 
**************************************************************** 
Configures a keyboard for a specific language.

KEYB [xx[,[yyy][,[drive:][path]filename]]] [/E] [/ID:nnn]

  xx                      Specifies a two-letter keyboard code.
  yyy                     Specifies the code page for the
                          character set.
  [drive:][path]filename  Specifies the keyboard definition file
  /E                      Specifies that an enhanced keyboard is
                          installed.
  /ID:nnn                 Specifies the keyboard in use.
 

**************************************************************** 
 
                LABEL COMMAND ONLINE DOCUMENTATION 
**************************************************************** 
Creates, changes, or deletes the volume label of a disk.

LABEL [drive:][label]
 

**************************************************************** 
 
                LH COMMAND ONLINE DOCUMENTATION 
**************************************************************** 
Loads a program into the upper memory area.

LOADHIGH [drive:][path]filename [parameters]
LOADHIGH [/L:region1[,minsize1][;region2[,minsize2]...] [/S]]
         [drive:][path]filename [parameters]

/L:region1[,minsize1][;region2[,minsize2]]...
            Specifies the region(s) of memory into which to load
            the program.  Region1 specifies the number of the
            first memory region; minsize1 specifies the minimum
            size, if any, for region1.  Region2 and minsize2
            specify the number and minimum size of the second
            region, if any.  You can specify as many regions as
            you want.

/S          Shrinks a UMB to its minimum size while the program
            is loading.

[drive:][path]filename
            Specifies the location and name of the program.


**************************************************************** 
 
                MD COMMAND ONLINE DOCUMENTATION 
**************************************************************** 
Creates a directory.

MKDIR [drive:]path
MD [drive:]path
 
 
 
**************************************************************** 
 
                MEM COMMAND ONLINE DOCUMENTATION 
**************************************************************** 
Displays the amount of used and free memory in your system.

MEM [/CLASSIFY | /DEBUG | /FREE | /MODULE modulename] [/PAGE]

  /CLASSIFY or /C  Classifies programs by memory usage. Lists the
                   size of programs, provides a summary of memory
                   in use, and lists largest memory block
                   available.
  /DEBUG or /D     Displays status of all modules in memory,
                   internal drivers, and other information.
  /FREE or /F      Displays information about the amount of free
                   memory left in both conventional and upper
                   memory.
  /MODULE or /M    Displays a detailed listing of a module's
                   memory use. This option must be followed by
                   the name of a module, optionally separated
                   from /M by a colon.
  /PAGE or /P      Pauses after each screenful of information.
 

**************************************************************** 
 
                MODE COMMAND ONLINE DOCUMENTATION 
**************************************************************** 
Configures system devices.

Printer port:      MODE LPTn[:] [COLS=c] [LINES=l] [RETRY=r]
Serial port:       MODE COMm[:] [BAUD=b] [PARITY=p] [DATA=d]
                        [STOP=s] [RETRY=r]
Device Status:     MODE [device] [/STATUS]
Redirect printing: MODE LPTn[:]=COMm[:]
Prepare code page: MODE device CP PREPARE=((yyy[...]) [drive:]
                        [path]filename)
Select code page:  MODE device CP SELECT=yyy
Refresh code page: MODE device CP REFRESH
Code page status:  MODE device CP [/STATUS]
Display mode:      MODE [display-adapter][,n]
                   MODE CON[:] [COLS=c] [LINES=n]
Typematic rate:    MODE CON[:] [RATE=r DELAY=d]
 

**************************************************************** 
 
                MORE COMMAND ONLINE DOCUMENTATION 
**************************************************************** 
Displays output one screen at a time.

MORE [drive:][path]filename
MORE < [drive:][path]filename
command-name | MORE [drive:][path][filename]

  [drive:][path]filename  Specifies file(s) to display one screen
                          at a time
  command-name            Specifies a command whose output will
                          be displayed.
 

**************************************************************** 
 
                MOVE COMMAND ONLINE DOCUMENTATION 
**************************************************************** 
Moves files and renames files and directories.

To move one or more files:
MOVE [/Y | /-Y] [drive:][path]filename1[,...] destination

To rename a directory:
MOVE [/Y | /-Y] [drive:][path]dirname1 dirname2

  [drive:][path]filename1 Specifies the location and name of the
                          file or files you want to move.
  destination             Specifies the new location of the file.
                          Destination can consist of a drive
                          letter and colon, a directory name, or
                          a combination. If you are moving only
                          one file, you can also include a
                          filename if you want to rename the file
                          when you move it.
  [drive:][path]dirname1  Specifies the directory you want to
                          rename.
  dirname2                Specifies the new name of the directory

  /Y              Suppresses prompting to confirm creation of a
                  directory or overwriting of the destination.
  /-Y             Causes prompting to confirm creation of a
                  directory or overwriting of the destination.

The switch /Y may be present in the COPYCMD environment variable.
This may be overridden with /-Y on the command line.
 

**************************************************************** 
 
                MSCDEX COMMAND ONLINE DOCUMENTATION 
**************************************************************** 
Illegal option '?'
usage: MSCDEX [/E/K/S/V] [/D:<driver> ... ] [/L:<letter>]
              [/M:<buffers>]
 

**************************************************************** 
 
                NLSFUNC COMMAND ONLINE DOCUMENTATION 
**************************************************************** 
Loads country-specific information.

NLSFUNC [[drive:][path]filename]

  [drive:][path]filename   Specifies the file containing
                           country-specific information.
 

**************************************************************** 
 
                PATH COMMAND ONLINE DOCUMENTATION 
**************************************************************** 
Displays or sets a search path for executable files.

PATH [[drive:]path[;...]]
PATH ;

Type PATH ; to clear all search-path settings and direct Windows
 to search only in the current directory.
Type PATH without parameters to display the current path.
 

**************************************************************** 
 
                PAUSE COMMAND ONLINE DOCUMENTATION 
**************************************************************** 
Suspends processing of a batch program and displays the message:
Press any key to continue....

PAUSE
 

**************************************************************** 
 
                PROMPT COMMAND ONLINE DOCUMENTATION 
**************************************************************** 
Changes the Windows command prompt.

PROMPT [text]

  text    Specifies a new command prompt.

Prompt can be made up of normal characters and the following
 special codes:

  $Q   = (equal sign)
  $$   $ (dollar sign)
  $T   Current time
  $D   Current date
  $P   Current drive and path
  $V   Windows version number
  $N   Current drive
  $G   > (greater-than sign)
  $L   < (less-than sign)
  $B   | (pipe)
  $H   Backspace (erases previous character)
  $E   Escape code (ASCII code 27)
  $_   Carriage return and linefeed

Type PROMPT without parameters to reset the prompt to the
 default setting.
 

**************************************************************** 
 
                RD COMMAND ONLINE DOCUMENTATION 
**************************************************************** 
Removes (deletes) a directory.

RMDIR [drive:]path
RD [drive:]path
 

**************************************************************** 
 
                REM COMMAND ONLINE DOCUMENTATION 
**************************************************************** 
Records comments (remarks) in a batch file or CONFIG.SYS.

REM [comment]
 

**************************************************************** 
 
                REN COMMAND ONLINE DOCUMENTATION 
**************************************************************** 
Renames a file/directory or files/directories.

RENAME [drive:][path][directoryname1 | filename1] [directoryname2
       | filename2]
REN [drive:][path][directoryname1 | filename1] [directoryname2
       | filename2]

Note that you cannot specify a new drive or path for your
 destination.
 

**************************************************************** 
 
                SCANDISK COMMAND ONLINE DOCUMENTATION 
**************************************************************** 
For information about the command-line parameters supported by 
ScanDisk for Windows, look up 'checking for errors, in disks' in 
the Windows Help index. Then view the topic 'Checking your disk 
for errors every time your computer starts.'
 

**************************************************************** 
 
                SET COMMAND ONLINE DOCUMENTATION 
**************************************************************** 
Displays, sets, or removes Windows environment variables.

SET [variable=[string]]

  variable  Specifies the environment-variable name.
  string    Specifies a series of characters to assign to the
            variable.

Type SET without parameters to display the current environment
 variables.
 

**************************************************************** 
 
                SETVER COMMAND ONLINE DOCUMENTATION 
**************************************************************** 
Sets the MS-DOS version number that Windows reports to a program.

Display current version table:  SETVER [drive:path]
Add entry:                      SETVER [drive:path] filename n.nn
Delete entry:                   SETVER [drive:path] filename
                                       /DELETE [/QUIET]

  [drive:path]    Specifies location of the SETVER.EXE file.
  filename        Specifies the filename of the program.
  n.nn            Specifies the MS-DOS version to be reported to
                  the program.
  /DELETE or /D   Deletes the version-table entry for the
                  specified program.
  /QUIET or /Q    Hides the message typically displayed during
                  deletion of version-table entry.
 

**************************************************************** 
 
                SMARTDRV COMMAND ONLINE DOCUMENTATION 
**************************************************************** 

Installs and configures the SMARTDrive disk-caching utility.

SMARTDRV [/X] [[drive[+|-]]...] [/U] [/C | /R] [/F | /N] [/L]
              [/V | /Q | /S]
         [InitCacheSize [WinCacheSize]] [/E:ElementSize]
         [/B:BufferSize]

/X              Disables write-behind caching for all drives.
drive           Sets caching options on specific drive(s). The
                specified drive(s) will have write-caching
                disabled unless you add +.
+               Enables write-behind caching for the specified
                drive.
-               Disables all caching for the specified drive.
/U              Do not load CD-ROM caching module.
/C              Writes all information currently in write-cache
                to hard disk. 
/R              Clears the cache and restarts SMARTDrive.
/F              Writes cached data before command prompt returns
                (default).
/N              Doesn't write cached data before command prompt
                returns.
/L              Prevents SMARTDrive from loading itself into
                upper memory.
/V              Displays SMARTDrive status messages when loading.
/Q              Does not display status information.
/S              Displays additional information about 
                SMARTDrive's status.
InitCacheSize   Specifies XMS memory (KB) for the cache.
WinCacheSize    Specifies XMS memory (KB) for the cache with
                Windows.
/E:ElementSize  Specifies how many bytes of information to move
                at one time.
/B:BufferSize   Specifies the size of the read-ahead buffer.
 

**************************************************************** 
 
                SORT COMMAND ONLINE DOCUMENTATION 
**************************************************************** 
Sorts input and writes results to the screen, a file, or another
 device

SORT [/R] [/+n] [[drive1:][path1]filename1] [> [drive2:][path2]
filename2][command |] SORT [/R] [/+n] [> [drive2:][path2]
filename2]

  /R                         Reverses the sort order; that is,
                             sorts Z to A, then 9 to 0.
  /+n                        Sorts the file according to
                             characters in column n.
  [drive1:][path1]filename1  Specifies file(s) to be sorted
  [drive2:][path2]filename2  Specifies a file where the sorted
                             input is to be stored.
  command                    Specifies a command whose output is
                             to be sorted.
 

**************************************************************** 
 
                START COMMAND ONLINE DOCUMENTATION 
**************************************************************** 
 

**************************************************************** 
 
                SUBST COMMAND ONLINE DOCUMENTATION 
**************************************************************** 
Associates a path with a drive letter.

SUBST [drive1: [drive2:]path]
SUBST drive1: /D

  drive1:        Specifies a virtual drive to which you want to
                 assign a path.
  [drive2:]path  Specifies a physical drive and path you want to
                 assign to a virtual drive.
  /D             Deletes a substituted (virtual) drive.

Type SUBST with no parameters to display a list of current
 virtual drives.
 

**************************************************************** 
 
                TIME COMMAND ONLINE DOCUMENTATION 
**************************************************************** 
Displays or sets the system time.

TIME [time]

Type TIME with no parameters to display the current time setting
 and a prompt for a new one.  Press ENTER to keep the same time.
 

**************************************************************** 
 
                TYPE COMMAND ONLINE DOCUMENTATION 
**************************************************************** 
Displays the contents of text files.

TYPE [drive:][path]filename


**************************************************************** 
 
                VER COMMAND ONLINE DOCUMENTATION 
**************************************************************** 
Displays the Windows version.

VER
 

**************************************************************** 
 
                VERIFY COMMAND ONLINE DOCUMENTATION 
**************************************************************** 
Tells Windows whether to verify that your files are written
 correctly to a disk.

VERIFY [ON | OFF]

Type VERIFY without a parameter to display the current VERIFY
 setting.
 

**************************************************************** 
 
                VOL COMMAND ONLINE DOCUMENTATION 
**************************************************************** 
Displays the disk volume label and serial number, if they exist.

VOL [drive:]
 

**************************************************************** 
 
                XCOPY COMMAND ONLINE DOCUMENTATION 
**************************************************************** 
Copies files and directory trees.

XCOPY source [destination] [/A | /M] [/D[:date]] [/P] [/S [/E]]
                           [/W] [/C] [/I] [/Q] [/F] [/L] [/H]
                           [/R] [/T] [/U] [/K] [/N]

 source       Specifies the file(s) to copy.
 destination  Specifies the location and/or name of new files.
 /A           Copies files with the archive attribute set,
              doesn't change the attribute.
 /M           Copies files with the archive attribute set,
              turns off the archive attribute.
 /D:date      Copies files changed on or after the specified date
              If no date is given, copies only those files whose
              source time is newer than the destination time.
 /P           Prompts you before creating each destination file.
 /S           Copies directories and subdirectories except
              empty ones.
 /E           Copies directories and subdirectories, including
              empty ones.  Same as /S /E. May be used to
              modify /T.
 /W           Prompts you to press a key before copying.
 /C           Continues copying even if errors occur.
 /I           If destination does not exist and copying more than
              one file, assumes that destination must be
              a directory.
 /Q           Does not display file names while copying.
 /F           Displays full source and destination file names
              while copying.
 /L           Displays files that would be copied.
 /H           Copies hidden and system files also.
 /R           Overwrites read-only files.
 /T           Creates directory structure, but does not copy
              files. Does not include empty directories or
              subdirectories. /T /E includes empty directories
              and subdirectories.
 /U           Updates the files that already exist in destination
 /K           Copies attributes. Normal Xcopy will reset
              read-only attributes.
 /Y           Overwrites existing files without prompting.
 /-Y          Prompts you before overwriting existing files.
 /N           Copy using the generated short names.


****************************************************************
