COMPUTING FOR THE BEWILDERED ============================ File Management --------------- As a companion to the presentation of file management in Moira Stephen's book, I'd like to spend some time going through the origins of the filing system usually used with the Windows operating system, which is based on the earlier DOS OS. The following has been adapted from an older booklet of mine written for classes taking a formal exam in file management; much of it is still relevant. Before I reproduce it, just a confirmation. Folders and Directories are exactly the same thing. Folders is the newer name, directories the older. FILES Work is stored on disk in FILES. Each file will have a filename and (usually) an extension. The filename can be up to 8 characters and the filename up to three. The name and extension are separated by a full stop. Windows 95 and later allow longer filenames. Examples of filenames are: CONFIG.SYS COMMAND.COM CHESS.EXE MYWORK.TXT READ.ME Certain extensions are reserved to mean certain things: SYS - a SYStem file or device driver COM - a COMmandable file EXE - an EXEcutable file BAT - a BATch file. SYS files are normally only accessed on system start-up or "boot" COM EXE and BAT files are the files which can be run from the "run" command or a command line. For the average user, there is no difference between COM and EXE programs. However, BAT files are text files of lists of instructions that are well within the capabilities of average users to create. BAT files were poorly catered for under Windows 95 and Windows 98. However, the most recent versions of Windows has reintroduced the concept, as a script file. Other extensions are conventionally used for specific purposes although not demanded by Windows. Some of the more common are: DOC - a document file created by a word processing package TXT - an ASCII text file INI - a program initiation file. DRIVES The different drives on your computer are labelled by letters of the alphabet followed by a colon, viz.: A: B: etc. All PCs have an A: This is the floppy drive from which the computer can be booted. A system disk in A: can always be used to boot from even if there is a bootable hard disk. A second floppy if fitted will be B:. If there is no second floppy, the first can also be accessed as B:. Windows has the ability to divide hard disks into partitions, each with its own drive letter. You may therefore have one hard disk which is divided into two or more drives (these are called logical drives), or you can have two or more hard disks, any of which may contain logical drives. Whatever the arrangement, the first partition on the first hard disk is C:, and is normally bootable, so the computer will boot without the need to insert a system disk. Large systems have many drives; the author's system currently goes to J:. Other devices, notably CD-ROM drives, also have a drive letter. These letters are allocated on boot after all the hard disk partitions have been accounted for. For most purposes, CD-ROMs can be regarded as very large read-only floppy disks! In order to make organising disks more easy, drives can be divided into subdirectories. Hard disks are always so divided, floppy disks less often. The root, or main directory, (sometimes called top level directory) is the one that always exists, and from which other directories, often called subdirectories, branch. The rules for directory names are exactly the same as those for files, although extensions are not normally used. The layout of directories and files on a disk is called a TREE. Here is a simple example: C: |-COMMAND.COM File in root directory |-AUTOEXEC.BAT " |-CONFIG.SYS " |-DOS Directory | |-CHKDSK.EXE File in DOS subdirectory | |-KEYB.COM " | |-etc. etc. |-WORKS Directory | |-WORKS.EXE File in WORKS subdirectory | |-WORDS Subdirectory of WORKS | | |-LETTER1.DOC File in WORKS\WORDS subdirectory | | |-LETTER2.DOC " | |-SPREAD Subdirectory of WORKS | | |-SHEET1.WS File in WORKS\SPREAD subdirectory | | |-SHEET2.WS " Note the use of the \ (backslash) above. To give the full location (PATH) of a file, we use the form: C:\WORKS\SPREAD\SHEET2.WS This means "the file SHEET2.WS, found in the SPREAD subdirectory of the WORKS subdirectory on C:" When housekeeping in DOS or Windows, it is not always necessary to quote the full path, but it is NEVER, EVER WRONG to do so, and may prevent errors. Although most file management operations are nowadays performed from the Windows desktop, command line operation is not only still a part of your tools, but has been brought back to prominence in Windows XP with the command interpreter CMD.EXE. It is not necessary to learn the command line in order to keep your disks in order, but it is often very much quicker.