APPLICATION NOTE #101: XYWRITE III AS A DOS SHELL Rev. 01 XyWrite is more than a word processing tool -- it also allows you to manage your disks and run other programs. You can even set up XyWrite to act as a DOS shell by following the instructions in this application note. WHAT IS A SHELL? A shell program is a command processor: it interprets the commands you enter and then runs the appropriate programs. The DOS shell program, called COMMAND.COM, contains internal commands that allow you to perform disk management functions, and a routine to load and execute external commands to run other programs. COMMAND.COM is one of three files that make up DOS. (The other files may be called IO.SYS and MSDOS.SYS or IBMBIO.COM and IB.COM, depending on the version of DOS you are using.) DOS normally requires that all three files be on the disk you use to start your computer, but with XyWrite you have the option of eliminating COMMAND.COM. XYWRITE FLEXIBILITY Unlike most application programs, XyWrite has a command interpreter built into it, which means you can start other programs from within XyWrite. You simply execute a DO command (see the XyWrite III Reference Guide for a description of the DO command); the program you are starting responds just as if you executed the command from DOS. In addition, XyWrite includes a variety of internal commands which allow you to perform disk management tasks without exiting to DOS. The table at the top of the next column lists these commands and provides a brief description. For detailed information, refer to the XyWrite III Reference Guide. SETTING UP XYWRITE AS A SHELL For XyWrite to act as a DOS shell: * Be sure you have enough memory. You need at least enough memory to run both XyWrite and any other program you want to use. We recommend that you have 640K of memory to use XyWrite as a shell. * Add the following line to the end of CONFIG.SYS: SHELL=EDITOR.EXE CONFIG.SYS is a DOS file that helps configure your system when you first start it. The file must be on the disk you use to start your computer (or in the root directory if you are using a hard disk). If the file does not already exist, create it and insert the SHELL=EDITOR.EXE line into it. XyWrite Disk Management Commands Command Description A: Sets the default drive. APPEND Adds one disk file to the bottom of another. CHDIR Changes to a new subdirectory. MKDIR Creates a new subdirectory. R Removes a subdirectory. COPY Copies a file. DIR Displays a disk directory. DIRL Displays a disk directory that includes the first few lines of text. DSORT Sets the sorting order for a directory display. DO Runs an external program. DOS Loads a copy of COMMAND.COM into memory. (COMMAND.COM must be on the default drive.) ERASE Deletes a file from disk. EXIT Returns to XyWrite from COMMAND.COM. FIND Searches through all files on a disk for a file you specify. RENAME Changes the name of a file. TREE Displays all of the subdirectories. Once you have changed CONFIG.SYS, you can delete COMMAND.COM from your disk. STARTING THE XYWRITE SHELL To begin using XyWrite as a DOS shell program, all you need to do is restart your computer. DOS will process the CONFIG.SYS file and load XyWrite instead of COMMAND.COM. QUITTING XYWRITE When you are using XyWrite as a DOS shell, the only way you can quit XyWrite is to turn off your computer. (Be sure all of your files are stored first!) Do not use the QUIT command or the Ctrl-Alt-Del key combination: both will lock up your computer.