An external command starting with DOS 5 that provides command history and macros (typed-in commands stored for later use). The command buffer (reserved space) is 512 bytes long unless you specify otherwise. Three examples for loading Doskey follow:
doskey 512 byte buffer
doskey /bufsize=1000 1K buffer
doskey /bufsize=256 minimum size
Use Up and Down Arrow to move through command history, and press Page Up and Page Down for the oldest and most recent command. Doskey uses these additional key commands:
Key Function F7 Display command history Alt-F7 Clear command history Alt-F10 Clear macros F9 Recall command by number Ctrl <-- Cursor previous word Ctrl --> Cursor next word Home Cursor beginning of line End Cursor end of line Esc Clear line Ins Insert mode for this line
CREATING MACROS
Doskey macros are useful for shortening phrases that are hard to type; for example, suppose you often copy the file D:\PKWARE\PKUNZIP.EXE to different directories or disks. You could create a macro named PK as follows:
doskey pk = copy d:\pkware\pkunzip.exe $1
The $1 creates a blank field for data entry. Now that the macro is created, to copy PKUNZIP.EXE to the B drive, you would type:
pk b:
Entering the command above converts the macro into the following command (the b: replaces the $1):
pk = copy d:\pkware\pkunzip.exe b:
To see the macros you've created, type:
doskey /macros
Doskey macros last for only the current session. If you save them in a batch file and add the word DOSKEY in front of each one, you can execute the batch file and recreate the macros in the next session. To store your macros in MYMACRO.BAT, type:
doskey /macros > mymacro.bat
In order to make the resulting file a command file, you have to type the word DOSKEY at the beginning of each line.
Download Computer Desktop Encyclopedia to your iPhone/iTouch




