Introduction
Entering Commands
Help!
File Names
Directories
Commands A-C
Commands D-F
Commands G-L
Commands M-Z
Wildcards
Command Line Buffer
Redirecting
Piping
More Keys
Tips, Tricks & Hints
Closing
Legal Notices

DOS Commands A-C

APPEND - ATTRIB - BREAK - CD or CHDIR - CHKDSK - CLS - COPY


APPEND - Enables programs to open data files in specific directories even if you are not in the directory.

Syntax - APPEND drive:\PATH;drive:\PATH.../SWITCHES
EXAMPLES:
APPEND - If you use APPEND alone it displays the list of
appended directories.
APPEND ; - Cancels the existing list of appended directories.
SWITCHES:
/X[:ON|:OFF] - Specifies whether MS-DOS is to search (/X:ON) or not
search (/X:OFF) appended directories when executing
programs. You can abbreviate /X:ON to /X. If you want
to specify X:ON, you must do it the first time you use
APPEND after starting your system. After that, you can
switch between X:ON and X:OFF.

The default value is /X:OFF.

/PATH:ON|
/PATH:OFF
- Specifies whether a program is to search appended directories
for a data file when a path is already included with the name
of the file the program is looking for.

The default setting is /PATH:ON.

/E - Assigns the list of appended directories to an environment
variable named APPEND. This switch can be used only the
first time you use APPEND after starting your system. If
you use /E, you can use the SET command to display the
list of appended directories.

DO NOT USE APPEND WITH
WINDOWS OR THE WINDOWS SETUP!

TOP


ATTRIB - Displays or changes file attributes.

Syntax - ATTRIB SWITCHES PARAMETERS
EXAMPLES:
ATTRIB C:\ - Displays the file attributes for all the files in the
root directory of the C drive.
PARAMETERS: The drive, path and/or file(s)
SWITCHES:
+R - Makes a file read only.
-R - Removes the read only attribute.
+A - Makes the file archive.
-A - Removes the file archive.
+S - Makes a file a system file.
-S - Removes the system file attribute.
+H - Makes a file/directory hidden.
-H - Unhides the file/directory
/S - Does files in current directory and subdirectories.

Wildcards can be used with this command.

TOP


BREAK - The break command alone shows the status of the BREAK command, whether or not it is set on or off, and whether it is set on or off determines when the computer checks for CTRL-C breaking.

If you type BREAK OFF the computer will check for CTRL-C during processes that update the screen, printing or keyboard buffer.

If you type BREAK ON the computer will check for CTRL-C during the same functions as BREAK OFF but also checks for CTRL-C during other functions such as disk reading and writing. BREAK ON may slow your computer down some.

TOP


CD or CHDIR - Both of these commands change the currently logged directory or
sub-directory. These commands also display the currently logged
directory if used alone.

Syntax - CD or CHDIR DIRECTORY
EXAMPLES:
CD\DOS or CD DOS - Both of these will take you to the same directory if you
are in the root directory.
CD.. - Takes you back one directory or subdirectory.
CD or CHDIR - Both of these will display the currently logged directory.
CD A:\TEXT - Changes the A Drive to the TEXT directory without
logging onto the drive.
CD\DOS - Will take you to the root directory then to the DOS
directory if you are in a directory or subdirectory.
CD..\GAMES - Will take you back one directory then to the
destination if its located in the current directory
or subdirectory.

To change drives you simply type the drive letter followed by a colon.

EXAMPLES:
A: or C: - These commands take you to there respective drives. Just
change the drive letter to the letter you wish to goto to.

TOP


CHKDSK - This command analyzes, diagnoses and optionally corrects common hard drive errors. It also tells information on the the size of the drive,free space, amount of total memory and free memory.

Syntax - CHKDSK DRIVE:/SWITCHES
EXAMPLES:
CHKDSK - When run alone it checks the current drive.
CHKDSK A:\ - Checks the A drive if on another drive. You can
also substitute the A for another drive letter.
CHKDSK /V - This will check the current drive and enable
auto-correction.
SWITCHES:
/F - Enables auto-correction and converts lost allocations to files.
/V - Displays the name of each file and directory on the drive as
it is checked.

TOP


CLS - Will clear everything on the screen.

TOP


COPY - Copies and combines files. Can also overwrite them.

Syntax - COPY SOURCE:\PATH\FILES TARGET:\PATH\FILES/SWITCHES
COPY SOURCE FILE(S)+SOURCE FILE(S)
TARGET:\PATH\FILES/SWITCHES
EXAMPLES:
COPY C:\1.TXT A:\ - This copies the file 1.TXT to the A drive.
COPY C:\1.TXT+2.txt C:\3.TXT - This copies,combines, the files 1.TXT and 2.TXT
to the file 3.TXT.
SWITCHES:
/A - Indicates that files are to be treated as ASCII files.
/B - Indicates that files are to be treated as binary files.
/V - Tells DOS to check validity on the target files after they are created.
/Y - Forces overwriting of existing files with the same name without prompting.
/-Y - Forces confirmation before files are overwriten, this is the default, use
only if the /Y switch has been set as the default.

Wildcards can be used with this command.

TOP