Native Windows 95 Commands

A native command takes advantage of the 32-bit operating system. Most commands familiar to MS-DOS users are now native Windows 95 system commands.

Some commands, such as dir and chdir, are internal, meaning the command resides in memory at all times. Internal commands can be run at the command prompt and in batch files.

Other commands, such as drvspace and xcopy, are external, meaning the command is stored in its own file and loads from disk when you use the command. External commands can be run at the command prompt, from Windows Explorer, from the Run command, or from the Start menu, and can also be run in batch files. Batch commands are for use in batch programs only, as described later in this appendix.

The following tables summarize the commands included with Windows 95. Unless otherwise specified, you can type these commands at the command prompt.

Internal1 and External2 Commands

Command

Purpose

attrib2

Displays or changes file attributes.

break1

Sets or clears extended CTRL+C checking.

cd1

Displays the name of the current directory or changes the current directory.

chcp1

Displays the number of the active character set (code page). You can also use this command to change the active character set for all devices that support character-set switching.

chdir1

See the cd command.

chkdsk2

Checks the status of a disk and displays a status report. Can also fix disk errors. However, Windows ScanDisk (scandskw) is the recommended command for repairing disks.

cls1

Clears the screen.

command2

Starts a new instance of the command interpreter.

copy1

Copies one or more files to the location you specify.

ctty1

Changes the terminal device used to control the computer.

date1

Displays the date and prompts you to change the date, if necessary.

drvspace2

Compresses hard disk drives or floppy disks, and configures drives that were compressed by using DriveSpace or DoubleSpace. This is a Windows-based utility; for information, see the syntax description later in this appendix.

debug2

Starts the Debug program, which you can use to test and debug executable files.

defrag2

Reorganizes the files on a disk to optimize disk performance. This is a Windows-based utility; for information, see the syntax description later in this appendix.

del (erase)1

Deletes the files you specify.

deltree2

Deletes a directory and all the files and subdirectories that are in it.

dir1

Displays a list of the files and subdirectories that are in the current or specified directory.

diskcopy2

Copies the entire contents of one floppy disk to another floppy disk.

doskey2

Loads the Doskey program into memory. The Doskey program recalls command-line commands, and it enables you to edit command lines and create and run macros. Doskey loads by default.

edit2

Starts a text editor you can use to create and edit ASCII text files.

emm3862

Enables or disables EMM386 expanded-memory support. Also provides support for loading real-mode device drivers in the upper memory area if both EMM386.EXE and HIMEM.SYS are loaded with device= commands in CONFIG.SYS.

erase1

See the del command.

exit1

Quits the command interpreter (COMMAND.COM) and returns to the program that started the command interpreter, if one exists.

expand2

Decompresses a compressed file.

fc2

Compares two files and displays the differences between them.

fdisk2

Starts the Fdisk program, which configures a hard disk for use with Windows 95. Although you can run this command at the command prompt, you cannot use it while running Windows 95 on the drive that contains the Windows system files.

find2

Searches for a specific string of text in a file or files.

for2

Runs a specified command for each file in a set of files.

format2

Formats a disk for use with Windows 95 or MS-DOS. You can use the right-click a drive icon in Windows Explorer to use a Windows-based version of this command.

keyb2

Starts the Keyb program, which configures a keyboard for a specific language.

label2

Creates, changes, or deletes the volume label (name) of a disk.

lh1

See the loadhigh command.

loadfix2

Ensures that a program is loaded above the first 64K of conventional memory.

loadhigh (lh)1

Loads a program into upper memory.

md1

Creates a directory or subdirectory.

mem2

Displays the amount of used and free memory on the computer.

mkdir1

See the md command.

mode2

Configures a printer, serial port, or display adapter; sets the typematic rate; redirects printer output from a parallel port to a serial port; prepares, selects, refreshes, or displays the numbers of the character sets (code pages) for parallel printers or the keyboard and screen; displays the status of all the devices installed on the computer.

more1

Displays one screen of output at a time.

move2

Moves one or more files to the location you specify. Can also be used to rename files and directories.

nlsfunc2

Starts the Nlsfunc program, which loads country-specific information for national language support (NLS).

path1

Indicates which directories the operating system should search for executable files (programs).

prompt1

Changes the appearance of the command prompt.

rd1

Deletes (removes) a directory.

ren1

Changes the name of the file or files you specify.

rename1

See the ren command.

rmdir1

See the rd command.

scandisk2

Checks disks and the file system for damage, and repairs them, if needed. Windows ScanDisk (scandskw) is the recommended command for repairing disks, as described later in this appendix.

set1

Displays, sets, or removes environment variables.

setver2

Displays the version table. Reports a version number to programs or device drivers designed for earlier versions of MS-DOS.

smartdrv2

Starts or configures SMARTDrive, which creates a disk cache in extended memory.

Important Under Windows 95, do not place the smartdrv command in AUTOEXEC.BAT. Windows 95 uses another method of disk caching.

sort2

Reads input, sorts data, and writes the results to the screen, a file, or another device.

start /W2

Allows you to run a Windows-based program from the command line and wait for it. For information about other switches that can be used with start, see the online Help for the command.

subst2

Associates a path with a drive letter.

sys2

Creates a startup disk by copying hidden Windows 95 system files and the command interpreter (COMMAND.COM) to the disk.

time1

Displays the system time or sets the computer's internal clock.

type1

Displays the contents of a text file.

ver1

Displays the operating system version number.

verify1

Directs the operating system to verify that files are written correctly to a disk, and displays the status of verification.

vol1

Displays the volume label and serial number for a disk, if the disk has them.

xcopy2

Copies directories, their subdirectories, and files (except hidden and system files). For details, see the syntax description later in this appendix.


1 Internal commands can be used in batch files and at the command prompt.

2 External commands can be run from the command prompt or in batch files, or can be run from Windows Explorer, the Run command, or other parts of the Windows 95 user interface.