home *** CD-ROM | disk | FTP | other *** search
/ Power-Programmierung / CD1.mdf / 4os2 / 4os2.inf (.txt) < prev    next >
OS/2 Help File  |  1993-03-07  |  146KB  |  5,082 lines

  1.  
  2. ΓòÉΓòÉΓòÉ 1. About 4OS2 Help ΓòÉΓòÉΓòÉ
  3.  
  4. 4OS2 On-line Documentation (Version 1.11, 3/93) 
  5.  
  6. Text by Rex Conn and Tom Rawson, originally converted to OS/2 format by Matthew 
  7. J. Palcic. 
  8.  
  9. Copyright 1992, 1993, Rex Conn and JP Software Inc., All Rights Reserved. 4OS2 
  10. is a trademark and 4DOS is a registered trademark of JP Software Inc.  OS/2 is 
  11. a registered trademark of IBM Corporation.  Other product and company names are 
  12. trademarks of their respective owners. 
  13.  
  14. This online help system for 4OS2 covers all 4OS2 features and internal 
  15. commands.  It includes reference information to assist you in using 4OS2 and 
  16. developing batch files; however it does not include all of the details which 
  17. are included in the printed 4OS2 and 4DOS manuals. 
  18.  
  19. The help system is fully indexed and cross-indexed.  It is also 
  20. context-sensitive; if you press F1 with a command already on the 4OS2 command 
  21. line, the help system will display help for that command.  If the line is blank 
  22. when you press F1, the help topic index is displayed. 
  23.  
  24. You can obtain "quick help" for any 4OS2 command directly on your 4OS2 screen 
  25. or window (without starting VIEW or switching back to the desktop) by entering 
  26. the command at the prompt followed by a /?. The quick help displays the syntax, 
  27. purpose, and switches for the command. 
  28.  
  29. 3/93-1.11A 
  30.  
  31.  
  32. ΓòÉΓòÉΓòÉ 2. Using 4OS2 ΓòÉΓòÉΓòÉ
  33.  
  34. This section includes information on: 
  35.  
  36.         Differences between 4DOS and 4OS2 
  37.         16 and 32 bit versions of 4OS2 
  38.         Command line editing keys 
  39.         Internal variables 
  40.         Variable functions 
  41.         Redirection 
  42.         Command grouping 
  43.         Wildcards 
  44.         Shared alias and history lists 
  45.         4OS2.INI 
  46.  
  47.  See the individual topics for details. 
  48.  
  49.  
  50. ΓòÉΓòÉΓòÉ 2.1. 4OS2 and 4DOS ΓòÉΓòÉΓòÉ
  51.  
  52. Most 4DOS commands and features work the same way in 4OS2.  However if you're 
  53. an experienced 4DOS user or want to use the same batch files and aliases in 
  54. both 4OS2 and 4DOS, there are some differences between 4DOS and 4OS2 you should 
  55. be aware of.  Those differences are listed here. 
  56.  
  57. (Several items below list elements of 4DOS which are not available under 4OS2. 
  58. In all cases these items have been removed from 4OS2 because they are specific 
  59. to DOS or for other similar reasons are not relevant or cannot be implemented 
  60. under OS/2.) 
  61.  
  62.     *   The default command separator is ^ in 4DOS; in 4OS2 it is & (for 
  63.         compatibility with CMD.EXE).  You can change it in 4OS2.INI or with the 
  64.         SETDOS /C command. 
  65.  
  66.     *   The default escape separator is  (Control-X) in 4DOS; in 4OS2 it is ^ 
  67.         (for compatibility with CMD.EXE).  You can change it in 4OS2.INI or 
  68.         with the SETDOS /E command. 
  69.  
  70.     *   The alias and variable parameter syntax is %n& in 4DOS; in 4OS2 it is 
  71.         %n$ (because & is normally used in 4OS2 as the command separator).  You 
  72.         can change it with the ParameterChar directive in 4OS2.INI or with the 
  73.         SETDOS /P command. 
  74.  
  75.     *   The following 4DOS commands do not exist in 4OS2: 
  76.  
  77.                BREAK            KEYSTACK         SWAPPING
  78.                CTTY             LOADHIGH / LH    TRUENAME
  79.  
  80.     *   The following 4DOS internal variables and variable functions do not 
  81.         exist in 4OS2: 
  82.  
  83.                %_ALIAS          %@EMS[]          %@REMOVABLE[]
  84.                %_DV             %@EXTENDED[]     %@TRUENAME[]
  85.                %_ENV            %@LPT[]          %@XMS[]
  86.                %_WIN
  87.  
  88.     *   New internal variables and variable functions available only in 4OS2 
  89.         include: 
  90.  
  91.                %_PID            %_SID            %@EXETYPE[]
  92.                %_PPID           %_PTYPE          %@FSTYPE[]
  93.  
  94.         Also the %_VIDEO internal variable returns some additional values in 
  95.         4OS2.  See 4OS2 Internal Variables and 4OS2 Variable Functions for more 
  96.         information. 
  97.  
  98.     *   The following 4DOS.INI directives cannot be used in 4OS2.INI: 
  99.  
  100.                Alias            Environment      ReserveTPA
  101.                ANSI             FineSwap         StackSize
  102.                AutoExecPath     FullINT2E        Swapping
  103.                ChangeTitle      HelpOptions      SwapReopen
  104.                CopyEA           HelpPath         UMBEnvironment
  105.                DiskReset        LineInput        UMBLoad
  106.                DRSets           MessageServer    UniqueSwapName
  107.                DVCleanup        NetwareNames
  108.                EnvFree          Reduce
  109.  
  110.         (The alias list size and environment size are set automatically by 
  111.         4OS2; other directives refer to features which are not relevant under 
  112.         OS/2.) 
  113.  
  114.     *   New directives available in 4OS2.INI which are not available in 
  115.         4DOS.INI include: 
  116.  
  117.                LocalAliases     LocalHistory     WindowState
  118.  
  119.         See 4OS2.INI for more information. 
  120.  
  121.  
  122. ΓòÉΓòÉΓòÉ 2.2. 16 and 32 Bit Versions of 4OS2 ΓòÉΓòÉΓòÉ
  123.  
  124. 4OS2 comes in two versions:  32-bit (4OS2/32) and 16-bit (4OS2/16).  4OS2/16 
  125. runs under OS/2 1.2, 1.3, 2.0, and above. 4OS2/32 runs only under OS/2 2.0 and 
  126. above.  If you use OS/2 version 2, you will find that 4OS2/32 offers a few 
  127. improvements and runs a bit faster than 4OS2/16. 
  128.  
  129. Caution:  4OS2/32 requires OS/2 2.0 with at least the XR06055 CSD (the "Service 
  130. Pack") installed.  4OS2/32 will not work properly with earlier versions of OS/2 
  131. (it will behave erratically, and some commands will not work at all).  4OS2/32 
  132. will work properly on later versions of OS/2, including the "2.01" and "2.1" 
  133. beta versions and subsequent releases. 
  134.  
  135. If you are unsure of what version of OS/2 you are running, and you have JP 
  136. Software's 4DOS, start a 4DOS session and enter the command VER /R.  Check the 
  137. displayed OS/2 Revision level.  This value must be 427 or greater for 4OS2/32 
  138. to work properly under OS/2 2.0. 
  139.  
  140. In this file, features which are available only in 4OS2/32 are marked with the 
  141. legend "4OS2/32 only".  If you don't see this legend, you can assume that the 
  142. feature you are reading about is available in both versions. 
  143.  
  144. For details on differences between 4OS2/32 and the 4OS2/16 see the following 
  145. topics in this file: 
  146.  
  147.         Shared alias and history lists 
  148.         DEL command (/F switch) 
  149.         MEMORY command 
  150.         START command (/DOS switch) 
  151.  
  152.  
  153. ΓòÉΓòÉΓòÉ 2.3. Editing the Command Line ΓòÉΓòÉΓòÉ
  154.  
  155. The 4OS2 command line offers full editing, and can also display the command 
  156. history in a window (see below).  The command line accepts up to 1023 
  157. characters. 
  158.  
  159. The following keys have special meaning when entered at the command line (the 
  160. caret ^ means press the Ctrl key together with the specified key): 
  161.  
  162.                   Move the cursor left one character. 
  163.                   Move the cursor right one character. 
  164.                   Recall the previous command from the history list, or match 
  165.                    a partial command entry with a history list entry. 
  166.                   Recall the next command from the history list, or match a 
  167.                    partial command entry with a history list entry. 
  168.     ^             Move the cursor left one word. 
  169.     ^             Move the cursor right one word. 
  170.     Home           Move the cursor to the beginning of the line. 
  171.     ^Home          Delete from the beginning of the line to the character 
  172.                    preceding the cursor. 
  173.     End            Move the cursor to the end of the line. 
  174.     ^End           Delete from the cursor to the end of the line. 
  175.     Ins            Toggle between insert and overstrike mode. 
  176.     Del            Delete the character at the cursor. 
  177.     Backspace      Delete the character to the left of the cursor. 
  178.     Enter          Execute the command. 
  179.     Esc            Erase the entire line. 
  180.     ^L             Delete the word to the left of the cursor. 
  181.     ^R             or ^Backspace  Delete the word to the right of the cursor. 
  182.     ^C             Abort the command. 
  183.     ^D             Delete the history list entry, and erase the line. 
  184.     ^E             Go to the last entry in the history list. 
  185.     ^K             Save the command to the history list without executing it, 
  186.                    and erase the line. 
  187.     F1             Call the on-line help. 
  188.     F3             Fill in the rest of the line (beyond any characters that 
  189.                    have already been typed) from the last line in the history. 
  190.     Tab            (or F9), Shift-Tab (or F8), F10  A Tab will scan the 
  191.                    filename (which may include the wildcard characters at or 
  192.                    immediately to the left of the cursor position, and replaces 
  193.                    it with the first matching filename.  Pressing Tab again 
  194.                    replaces it with the next matching filename; pressing F10 
  195.                    appends the next matching filename at the current cursor 
  196.                    position.  Pressing Shift-Tab will retrieve the previous 
  197.                    matching filename.  If you don't enter a filename, Tab 
  198.                    defaults to *.*.  If you don't enter an extension, Tab 
  199.                    appends a .*. 
  200.     PgUp           Popup a history window, showing those commands that match 
  201.                    characters already entered on the command line. 
  202.     ^PgUp          Popup a directory window, showing those directories recently 
  203.                    changed to with the CD, CDD, and PUSHD commands. 
  204.     Alt-255        (Hold down the Alt key and enter 255 on the numeric keypad.) 
  205.                    Accept the next character "as-is" from the keyboard and 
  206.                    enter it on the command line.  This allows you to enter 
  207.                    characters normally interpreted as editing keys (for 
  208.                    example, Esc). To enter the Alt-255 character itself into 
  209.                    the line, you must type it twice. 
  210.     ^ (caret)      "Escape" the next character (the default escape character 
  211.                    for 4OS2 and CMD.EXE is the caret ^; it can be changed in 
  212.                    4OS2 with the SETDOS command or in the 4OS2.INI file).  The 
  213.                    escape character forces the parser to ignore any special 
  214.                    meaning of the next character (for example, redirection 
  215.                    characters).  Note that 4OS2 will not recognize the escape 
  216.                    character inside double quotes (for compatibility with 
  217.                    CMD.EXE). 
  218.  
  219.                    Escaping the following characters will insert the specified 
  220.                    control code: 
  221.  
  222.                      b  bell (ASCII 7) 
  223.                      e  escape (ASCII 27) 
  224.                      f  form feed (ASCII 12) 
  225.                      n  line feed (ASCII 10) 
  226.                      r  carriage return (ASCII 13) 
  227.                      t  tab (ASCII 9) 
  228.  
  229.  The following keys have special meaning when entered from inside the popup 
  230.  history and directory windows.  The history list in a window is not circular 
  231.  as it is at the command line; scrolling and paging stop at the beginning or 
  232.  end of the history list. 
  233.  
  234.                  Move the highlight up one line. 
  235.                  Move the highlight down one line. 
  236.     PgUp          Move up one page. 
  237.     PgDn          Move down one page. 
  238.     Home          Move to the first line in the list. 
  239.     End           Move to the last line in the list. 
  240.     Enter         Execute the highlighted command (history window) or change to 
  241.                   the highlighted directory (directory window). 
  242.     ^Enter        Close the window and move the highlighted command to the 
  243.                   prompt for editing (history window only). 
  244.     Esc           Close the window and return to the previous command line at 
  245.                   the prompt. 
  246.     ^C            Close the window, abort any partially entered command line, 
  247.                   and redisplay the prompt. 
  248.  
  249.  Most of the command line and popup window keys, as well as the popup window 
  250.  location and size, can be redefined in the 4OS2.INI initialization file. 
  251.  
  252.  
  253. ΓòÉΓòÉΓòÉ 2.4. 4OS2 Internal Variables ΓòÉΓòÉΓòÉ
  254.  
  255. Environment variables are referenced in a command by starting the variable name 
  256. with a percent sign (%).  (If you want to enter a percent sign without 
  257. referring to a variable, use two percent signs (%%).)  An environment variable 
  258. name is terminated by either another percent sign, or by an invalid character 
  259. (see below).  To pass a variable name (instead of the value) to a command (for 
  260. example, in INKEY or INPUT), you must precede it with two percent signs. 
  261.  
  262. Environment variable names may be composed of any alphanumeric character, plus 
  263. the underscore (_), and $ characters.  In addition to the standard variable 
  264. name characters, you can force 4OS2 to accept any sequence of characters as a 
  265. valid variable name by enclosing them in square brackets. For example, %[AB##1] 
  266. refers to an environment variable named AB##1. 
  267.  
  268. Batch file variables are only active inside a batch file.  They are referenced 
  269. as %0 to %127, and expand to the matching argument on the command line that 
  270. started the batch file.  The parameter %n$ is a special case, and expands to 
  271. all arguments in the command line tail, starting at argument number n.  If n is 
  272. not specified, it defaults to 1 (so %$ will expand to all arguments in the 
  273. command line tail). 
  274.  
  275. There are some variable names that have special meanings in 4OS2.  Only CDPATH, 
  276. CMDLINE, and PATH are actually stored in the environment; the remainder are 
  277. internal to 4OS2, and cannot be viewed or modified with SET or ESET.  (The 
  278. internal variable names are checked after variable expansion, so they can be 
  279. overridden by creating an environment variable of the same name.) 
  280.  
  281. The 4OS2 internal variables are: 
  282.  
  283.     %#  returns the number of command line arguments in a batch file. 
  284.     %?  returns the exit code of the previous external command. 
  285.     %_? returns the exit code of the previous internal command.  (Save this 
  286.         value immediately; it is overwritten by the next internal command.) 
  287.     %+  returns the current command separator.  See the CommandSep directive in 
  288.         4OS2.INI or the SETDOS /C command for more details. 
  289.     %=  returns the current 4OS2 escape character.  See the EscapeChar 
  290.         directive in 4OS2.INI or the SETDOS /E command for more details. 
  291.     %CDPATH tells 4OS2 where to search for directories names specified by a CD 
  292.         or CDD command.  4OS2 will append the specified directory name to each 
  293.         directory in CDPATH and attempt to change to that directory. If you 
  294.         have already have a CDPATH environment variable, you can use %_CDPATH 
  295.         instead for the directory search. 
  296.     %CMDLINE is the fully expanded 1023-character command line for the external 
  297.         command.  You can access it from an external program by searching the 
  298.         environment. 
  299.     %COLORDIR is the "directory colorization" variable.  See DIR for details on 
  300.         the COLORDIR format. 
  301.     %PATH tells 4OS2 where to search for executable files: .COM, .EXE, .BTM, 
  302.         and .CMD (and .BAT in OS/2 2.0), in that order, not found in the 
  303.         current directory.  Some applications also use the PATH variable to 
  304.         find their files. 
  305.     %_4VER returns the 4OS2 version number (for example, 1.1). 
  306.     %_ANSI is 1 if ANSI is active (4OS2 always enables ANSI). 
  307.     %_BATCH is the current batch nesting level (0 if not in a batch file). 
  308.     %_BG is a string containing the screen background color at the current 
  309.         cursor position. 
  310.     %_BOOT returns the boot disk (for example, C). 
  311.     %_CODEPAGE is the current code page number. 
  312.     %_COLUMN is the current cursor column. 
  313.     %_COLUMNS is the current number of screen columns. 
  314.     %_CPU is the cpu type (286, 386, or 486). 
  315.     %_CWD is the current directory in the format d:\pathname. 
  316.     %_CWDS has the same value as CWD, except it ensures the pathname ends in a 
  317.         backslash (\). 
  318.     %_CWP is the current directory in the format \pathname. 
  319.     %_CWPS has the same value as CWP, except it ensures the pathname ends in a 
  320.         backslash (\). 
  321.     %_DATE contains the current system date, in the format mm-dd-yy (U.S.), 
  322.         dd-mm-yy (Europe), or yy-mm-dd (Japan). 
  323.     %_DISK is the current disk (for example, C). 
  324.     %_DOS is the operating system type (DOS or OS2).  This is useful if you 
  325.         have .BTM files running in both modes. 
  326.     %_DOSVER is the current OS/2 version (for example, 2.0). 
  327.     %_DOW is the current day (Mon, Tue, Wed, etc.). 
  328.     %_FG is a string containing the screen foreground color at the current 
  329.         cursor position. 
  330.     %_LASTDISK returns the last disk on the system (A: - Z:). 
  331.     %_MONITOR is the monitor type (MONO or COLOR). 
  332.     %_MOUSE returns 1 if a mouse is installed. 
  333.     %_NDP is the coprocessor type (0 - no coprocessor; 287 - 80287; 387 - 80387 
  334.         or 80486). 
  335.     %_PID is the process ID for 4OS2. 
  336.     %_PPID is the parent process ID (for the process that started 4OS2). 
  337.     %_PTYPE is the process type (FS - full screen; AVIO - Windowed; PM - 
  338.         Presentation manager; DT - detached). 
  339.     %_ROW is the current cursor row. 
  340.     %_ROWS is the current number of screen rows. 
  341.     %_SHELL is the current shell nesting level for that session.  The first 
  342.         copy of 4OS2 started in a session is shell 0. 
  343.     %_SID is the session ID. 
  344.     %_TIME contains the current system time in the format hh:mm:ss.  The 
  345.         separator character may vary depending upon your country information. 
  346.     %_TRANSIENT returns a 1 if the current shell is transient (started with a 
  347.         /C). 
  348.     %_VIDEO is the video card type (MONO, CGA, EGA, VGA, XGA, 8514, or IA/A). 
  349.  
  350.  
  351. ΓòÉΓòÉΓòÉ 2.5. 4OS2 Variable Functions ΓòÉΓòÉΓòÉ
  352.  
  353. Variable Functions are pseudo-variables that take one or more arguments (which 
  354. can themselves be environment variables or variable functions), and return a 
  355. value.  The variable function name must be preceded by an %@ (%@eval, %@len, 
  356. etc.).  All variable functions must have square brackets enclosing their 
  357. argument(s). 
  358.  
  359. Some functions return the number of bytes, kilobytes, or megabytes based on a 
  360. b|k|m argument: 
  361.  
  362.     b   bytes 
  363.     k   bytes / 1000 
  364.     K   kilobytes (bytes / 1024) 
  365.     m   bytes / 1,000,000 
  366.     M   megabytes (bytes / 1,048,576) 
  367.  
  368.  With such functions, you can append a c after the b|k|m character to return 
  369.  the value with the proper thousands delimiter every three characters.  For 
  370.  example, if MYFILE.DAT is 62,374 bytes long, then: 
  371.  
  372.       %@filesize[myfile.dat,b]      returns 62374
  373.       %@filesize[myfile.dat,bc]     returns 62,374
  374.  
  375.  Note that values with commas in them can not be used when performing numeric 
  376.  comparisons with the IF command. 
  377.  
  378.  The 4OS2 variable functions are: 
  379.  
  380.     %@ALIAS[name] returns the alias argument for the specified name. 
  381.     %@ASCII[c] returns the ASCII value of the specified character. 
  382.     %@ATTRIB[filename,attrib] returns a 1 if the specified file has the 
  383.         matching attribute(s).  The attributes (other than N) can be combined; 
  384.         ATTRIB will only return a 1 if _all_ the attributes match.  The 
  385.         attributes are: 
  386.           N  Normal (no attribute bits set) 
  387.           R  Read-only 
  388.           H  Hidden 
  389.           S  System 
  390.           D  Directory 
  391.           A  Archive 
  392.     %@CHAR[n] returns the character for the specified ASCII value. 
  393.     %@DATE[mm/dd/yy] returns the number of days since 1/1/80 for the specified 
  394.         date.  DATE will use the date format mandated by your country code 
  395.         (dd/mm/yy in Europe; yy/mm/dd in Japan). 
  396.     %@DESCRIPT[filename] returns the file's description. 
  397.     %@DEVICE[name] returns a 1 if the specified name is a character device. 
  398.     %@DISKFREE[d:,b|k|m[c]] returns the free disk space for the specified 
  399.         drive, in bytes, kilobytes, or megabytes. 
  400.     %@DISKTOTAL[d:,b|k|m[c]] returns the total disk space for the specified 
  401.         drive, in bytes, kilobytes, or megabytes. 
  402.     %@DISKUSED[d:,b|k|m[c]] returns the disk space used on the specified drive, 
  403.         in bytes, kilobytes, or megabytes. 
  404.     %@DOSMEM[b|k|m[c]] returns the size of the largest free OS/2 memory block 
  405.         in bytes, kilobytes, or megabytes.  Due to OS/2's virtual memory 
  406.         system, this value is only a general reflection of available memory and 
  407.         not a precise statement of the RAM available for applications. 
  408.     %@EVAL[expression] evaluates an arithmetic expression.  It supports 
  409.         addition (+), subtraction (-), multiplication (*), division (/), and 
  410.         modulo (%%).  The expression can contain environment variables, 
  411.         including other variable functions.  EVAL supports commas and decimal 
  412.         places; the maximum size is 16.8 (16 integer and 8 decimal places). 
  413.         EVAL strips leading and trailing zeros from the result. 
  414.     %@EXEC[command] executes the command and returns its exit code.  The 
  415.         command can be an alias, an internal 4OS2 command, or an external 
  416.         program or batch file.  This is a back door entry to 4OS2 command 
  417.         processing -- use with caution! 
  418.     %@EXETYPE[filename] returns the file's program type: 
  419.         UNKNOWN  Unknown type 
  420.         FS  Full-screen OS/2 
  421.         AVIO  Windowable OS/2 
  422.         PM  Presentation manager OS/2 
  423.         DOS  MS-DOS (OS/2 2.0 only) 
  424.         WIN  Windows 3 (OS/2 2.0 only) 
  425.     %@EXT[filename] returns the file extension (without a leading period). 
  426.     %@FILEDATE[filename] returns the last modification date for the file, in 
  427.         the default country format (mm-dd-yy for US). 
  428.     %@FILESIZE[filename,b|k|m[c]] returns the size of the file in bytes, 
  429.         kilobytes, or megabytes, or -1 if the file doesn't exist. 
  430.     %@FILETIME[filename] returns the last modification time for the file, in 
  431.         hh:mm format. 
  432.     %@FULL[filename] returns the fully qualified path name. 
  433.     %@FSTYPE[d:] returns the drive's file system type (for example, FAT or 
  434.         HPFS). 
  435.     %@INDEX[string1,string2] returns the position of string2 within string1, or 
  436.         -1 if string2 is not found.  The first position in string1 is 0. 
  437.     %@INT[n] returns the integer part of "n".  See %@EVAL. 
  438.     %@LABEL[d:] returns the volume label of the specified disk. 
  439.     %@LEN[string] returns the length of the string. 
  440.     %@LINE[filename,n] returns line "n" from the specified file.  If you 
  441.         specify "CON" for the filename, it will read from standard input. 
  442.     %@LINES[filename] returns the number of lines in the specified file, base 
  443.         0.  If there are no lines, it returns -1. 
  444.     %@LOWER[string] returns the string converted to lower case. 
  445.     %@MAKEDATE[n] returns the date given the number of days since 1/1/80. 
  446.     %@MAKETIME[n] returns the time given the number of seconds since midnight. 
  447.     %@NAME[filename] returns the filename only (no path or extension). 
  448.     %@PATH[filename] returns the path only (including the trailing backslash). 
  449.     %@READSCR[row,column,length] returns the text on the screen at the 
  450.         specified row and column, for the specified length. 
  451.     %@READY[d:] returns a 1 if the specified drive is ready. 
  452.     %@REMOTE[d:] returns a 1 if the specified drive is remote (LAN). 
  453.     %@REMOVABLE[d:] returns a 1 if the specified drive has removable media 
  454.         (floppy, CD_ROM, etc.). 
  455.     %@SEARCH[filename] searches for an executable file using the PATH 
  456.         environment variable, appending the extension if one wasn't specified. 
  457.     %@SELECT[filename,top,left,bottom,right,title] displays the file as a popup 
  458.         selection list.  If you press Enter, it returns the string highlighted 
  459.         by the selection bar; if you press Esc it returns an empty string.  If 
  460.         you specify "CON" for the filename, it will read from standard input. 
  461.     %@SUBSTR[string,start,length] returns a substring, starting at the position 
  462.         "start" and continuing for "length" characters.  If the length is 
  463.         negative, the start is relative to the right side.  If the length isn't 
  464.         specified, SUBSTR will return the remainder of the string.  For 
  465.         example, %@SUBSTR[%_time,0,2] gets the current time and extracts the 
  466.         hour.  If the string includes commas it must be quoted with double 
  467.         quotes or single back-quotes (" or `). 
  468.     %@TIME[hh:mm:ss] returns the number of seconds since midnight for the 
  469.         specified time.  The time must be in 24-hour format. 
  470.     %@UNIQUE[d:\path] returns a unique filename in the specified drive and 
  471.         path. 
  472.     %@UPPER[string] returns the string converted to upper case. 
  473.     %@WORD[n,string] returns the "nth" word in the string (base 0).  If "n" is 
  474.         negative, WORD starts from the end and counts backwards. 
  475.  
  476.  
  477. ΓòÉΓòÉΓòÉ 2.6. Redirection and Piping ΓòÉΓòÉΓòÉ
  478.  
  479. Redirection 
  480.  
  481. OS/2 assumes input comes from the keyboard and output goes to the display. The 
  482. keyboard is referred to as standard input, and the display is referred to as 
  483. standard output.  You can change the default standard input and standard output 
  484. by using the < and > symbols on the command line.  4OS2 also allows you to 
  485. redirect the standard error by appending an & character. 
  486.  
  487. To get standard input from a file instead of the keyboard: 
  488.  
  489.     < filename
  490.  
  491. To redirect standard output to a file: 
  492.  
  493.     > filename
  494.  
  495. To redirect standard output and standard error to a file: 
  496.  
  497.     >& filename
  498.  
  499. To redirect standard error only to a file: 
  500.  
  501.     >&> filename
  502.  
  503. To append standard output or standard error to a file, use >> in place of the 
  504. first >.  If NOCLOBBER is set, the file must exist before it can be appended to 
  505. (unless overridden by a !). Otherwise, 4OS2 will create the file. 
  506.  
  507. 4OS2 also supports the OS/2 CMD.EXE syntax: 
  508.  
  509.     n>file
  510.  
  511. and 
  512.  
  513.     n>&m
  514.  
  515. where n and m are digits from 0 to 9.  You may not put any spaces between the n 
  516. and the >, or between the & and the m in the second form.  The digits represent 
  517. file handles:  0, 1, and 2 are predefined by OS/2 as standard input, standard 
  518. output, and standard error respectively; 3 through 9 can be defined by 
  519. applications. 
  520.  
  521. The n>file syntax redirects output from handle n to a file.  The n>&m syntax 
  522. redirects handle n to the same location as the previously assigned handle m. 
  523. In many cases you can perform the same operations by using 4OS2's enhanced 
  524. redirection features.  See the 4OS2 manual for more information on these 
  525. options. 
  526.  
  527. Piping 
  528.  
  529. Piping makes the standard output of one command the standard input for a second 
  530. command.  To send the standard output of "cmd1" to the standard input of 
  531. "cmd2": 
  532.  
  533.     cmd1 | cmd2
  534.  
  535. To send the standard output and standard error of "cmd1" to the standard input 
  536. of "cmd2": 
  537.  
  538.     cmd1 |& cmd2
  539.  
  540. Unlike 4DOS, which creates a temporary file for pipes, 4OS2 connects a pipe 
  541. directly to a secondary process; both processes execute simultaneously. 
  542.  
  543.  
  544. ΓòÉΓòÉΓòÉ 2.7. Command Grouping ΓòÉΓòÉΓòÉ
  545.  
  546. Command grouping allows you to logically group a set of commands together by 
  547. enclosing them with parentheses.  For example, this grouping: 
  548.  
  549.     (global /iq echo %_cwd) > dirlist
  550.  
  551. allows you to redirect all output from GLOBAL to the specified file.  The 
  552. following command will take the output of DIR and TYPE, sort the whole mess, 
  553. and save it in the file AZ: 
  554.  
  555.     (dir *.com & type autoexec.bat) | sort > AZ
  556.  
  557. To group commands, the first character of the command must begin with a (  Note 
  558. that if you have a closing parenthesis ) in a filename, you'll need to escape 
  559. it with the 4OS2 escape character (^) to keep 4OS2 from assuming it's the end 
  560. of the command group. 
  561.  
  562. You can also use command grouping to split commands over several lines. For 
  563. example: 
  564.  
  565.     for %x in (*.c) do (
  566.         echo %x
  567.         dir *.c
  568.     )
  569.  
  570. If you enter a command group on the command line without a closing parenthesis, 
  571. 4OS2 will prompt you with More? for the remainder of the line. 
  572.  
  573.  
  574. ΓòÉΓòÉΓòÉ 2.8. Wildcards ΓòÉΓòÉΓòÉ
  575.  
  576. Wildcards let you specify a file or group of files by typing a partial 
  577. filename.  Most internal commands accept filenames with wildcards anywhere a 
  578. full filename can be used.  4OS2 recognizes 3 wildcard types: asterisk *, 
  579. question mark ?, and square brackets [ ].  You can combine various wildcard 
  580. types in a single filename. Note that the 4OS2 wildcard extensions may not be 
  581. interpreted properly by external programs, so when passing file names to 
  582. external programs you should use the traditional wildcard syntax. 
  583.  
  584. A * in a filename means "any zero or more characters in this position."  You 
  585. can use both leading and trailing asterisks. For example, to get a directory of 
  586. all files beginning with "ab": 
  587.  
  588.     dir ab*.*
  589.  
  590. To get a directory of all files with an "ab" anywhere in the filename: 
  591.  
  592.     dir *ab*.*
  593.  
  594. A ? matches any single filename character.  A ? doesn't require that a 
  595. character exist if it's at the end of the filename or extension. 
  596.  
  597. A set of characters in brackets [ ] acts like a ? (match any single character), 
  598. but allows you to specify or exclude specific characters.  If you specify one 
  599. or more characters in the brackets (e.g. [abc]), the specification will only 
  600. match files whose names have one of the listed characters in the corresponding 
  601. position.  For example, to get a directory of all files whose names have either 
  602. a "p" or "q" as the first letter: 
  603.  
  604.     dir [pq]*.*
  605.  
  606. Two characters with a dash (-) between them represent a range of characters, 
  607. and will match any character within the range (including the beginning and end 
  608. characters).  For example, to get a directory of all files with names beginning 
  609. with a number from 1 to 6, or the letters "a" or "b", and ending with a "9": 
  610.  
  611.     dir [1-6ab]*9.*
  612.  
  613. If you enter a ! as the first character following the left bracket, the test is 
  614. reversed (only match names that do not have the listed characters in the 
  615. corresponding position).  For example, to get a directory of all files with 
  616. names of two characters or more that begin with an "a" and do not have a digit 
  617. as the second character: 
  618.  
  619.     dir a[!0-9]*.*
  620.  
  621. The special wildcard construct [?] will match any character (like ?) but will 
  622. require that the character exist, even at the end of a filename or extension. 
  623. For example, if you have the files XYZ.DAT and XY.DAT in the current directory, 
  624. then: 
  625.  
  626.     dir xy?.dat         will display both file names
  627.     dir xy[?].dat       will display only XYZ.DAT
  628.  
  629.  
  630. ΓòÉΓòÉΓòÉ 2.9. Shared Alias and History Lists ΓòÉΓòÉΓòÉ
  631.  
  632. By default, 4OS2 will use the same history list and alias list in all sessions 
  633. and in both primary and secondary 4OS2 shells.  It keeps these lists in shared 
  634. memory segments.  This means that the aliases that you define in one session 
  635. will be available immediately in copies of 4OS2 that are running in other 
  636. sessions.  In addition, the history list is updated in all 4OS2 sessions 
  637. whenever you type a command at any 4OS2 prompt. 
  638.  
  639. If you want to start a 4OS2 shell or session with unique alias and history 
  640. lists, use the LocalAlias and / or LocalHistory Initialization Directives  in 
  641. 4DOS.INI.  Using the 4OS2.INI directive is the best choice if you want to have 
  642. separate alias and history lists for all 4OS2 sessions. You can also place 
  643. these directives on the command line if you want to create a separate list just 
  644. for one particular session or shell. 
  645.  
  646. The memory segments that contain the shared history and alias lists are 
  647. retained as long as there is at least one copy of 4OS2 running that supports 
  648. shared lists.  When all such copies of 4OS2 end, the shared history and alias 
  649. lists are discarded. 
  650.  
  651. A utility program called SHRALIAS.EXE is included on the 4OS2 distribution 
  652. diskette.  It will keep these lists open until your computer is rebooted.  To 
  653. use this program, include the following line in your STARTUP.CMD, 4START, or 
  654. 4OS2 session startup batch file: 
  655.  
  656.     [d:\path\]shralias
  657.  
  658. Once SHRALIAS is started, it will remain active until your computer is turned 
  659. off or rebooted, even if the session from which it was started is terminated. 
  660. To deactivate SHRALIAS, enter this command at any 4OS2 prompt: 
  661.  
  662.     [d:\path\]shralias /u
  663.  
  664. If you are using 4OS2/16 (see 16 and 32 bit versions of 4OS2), the SHRALIAS 
  665. program is in the file SHRALS16.EXE on the distribution disk. If you are using 
  666. 4OS2/32, SHRRALIAS is in the file SHRALS32.EXE.  These files are renamed 
  667. automatically to SHRALIAS.EXE during installation from diskettes.  If you have 
  668. a downloaded copy of 4OS2 the proper copy is in the ZIP file you downloaded, 
  669. and is already named SHRALIAS.EXE (see the README.DOC file which came with your 
  670. downloaded copy for details).  You must use the correct version of SHRALIAS for 
  671. the version of 4OS2 you are running.  The 16-bit SHRALIAS program will not keep 
  672. shared alias and history lists open for 4OS2/32, and SHRALS32 will not do so 
  673. for 4OS2/16. 
  674.  
  675.  
  676. ΓòÉΓòÉΓòÉ 2.10. 4OS2 Initialization File (4OS2.INI) ΓòÉΓòÉΓòÉ
  677.  
  678. The 4OS2.INI file is an ASCII file containing directives to control the 
  679. configuration of 4OS2 in primary and secondary shells.  Blank lines are ignored 
  680. and can be used to separate groups of directives.  You can place comments in 
  681. the file by beginning a line with a semicolon (;). You can also place comments 
  682. at the end of any line except one containing a text string value by entering at 
  683. least one space or tab after the value, a semicolon, and your comment. 
  684.  
  685. The file has two sections, identified by a name in square brackets on a line by 
  686. itself.  The section names are: 
  687.  
  688.     [Primary]           Directives in this section will be used when 4OS2 is 
  689.                         running as the primary shell (i.e., when a session is 
  690.                         started). 
  691.  
  692.     [Secondary]         Directives in this section are used in secondary shells 
  693.                         only (i.e., a second invocation of 4OS2 within the same 
  694.                         session), and override any corresponding primary shell 
  695.                         settings. 
  696.  
  697.  Lines before a section name are used in both primary and secondary shells. 
  698.  
  699.  When 4OS2 is loaded, whether as the primary or secondary shell, it first 
  700.  checks for an "@d:\path\inifile" option on the command line (you can set this 
  701.  option in the Parameters field of the Settings notebook for any icon that 
  702.  starts a 4OS2 session).  If this option is found 4OS2 looks for the specified 
  703.  file, and skips the search for the default 4OS2.INI file. 
  704.  
  705.  If no INI file name is specified on the command line, 4OS2 looks for 4OS2.INI 
  706.  in the same directory as 4OS2 itself, then in the root directory of the system 
  707.  boot drive. 
  708.  
  709.  Directives in 4OS2.INI are divided into four types: 
  710.  
  711.         Initialization directives 
  712.         Configuration directives 
  713.         Color directives 
  714.         Key mapping directives 
  715.  
  716.  See the individual topics for details. 
  717.  
  718.  
  719. ΓòÉΓòÉΓòÉ 2.10.1. Initialization Directives ΓòÉΓòÉΓòÉ
  720.  
  721. These directives control how 4OS2 starts and where it looks for its files. 
  722.  
  723.  4StartPath= Path:  Sets the drive and directory where 4OS2 will look for the 
  724.      4START and 4EXIT batch files. 
  725.  History= nnnn (1024):  Sets the history list size (in bytes).  The range is 
  726.      512 to 8192 bytes. 
  727.  LocalAliases= Yes | NO:  "Yes" tells 4OS2 to create a local alias list for 
  728.      this session.  "No" causes 4OS2 to use the global alias list shared by all 
  729.      sessions. 
  730.  LocalHistory= Yes | NO: "Yes" tells 4OS2 to create a local history list for 
  731.      this session.  "No" causes 4OS2 to use the global history list shared by 
  732.      all sessions. 
  733.  LogName= File (none):  Sets the log file name and/or path.  If only a path is 
  734.      given, 4OS2 will use the default log file name (4OS2LOG).  Using LogName 
  735.      does not turn logging on, you must still use LOG ON to do so. 
  736.  NextINIFile= File (none):  Full path and name must be specified.  All 
  737.      subsequent shells will read the specified INI file, and ignore any 
  738.      [Secondary] section in the original 4OS2.INI.  Allows workstation users to 
  739.      shift 4OS2.INI to a network drive for secondary shells. 
  740.  PauseOnError= YES | No:  "Yes" tells 4OS2 to pause with the message "Error in 
  741.      4OS2.INI, press any key to continue processing" after displaying any error 
  742.      message related to a specific line in the 4OS2.INI file.  "No" continues 
  743.      processing with no pause after an error message is displayed. 
  744.  WindowState= STANDARD | Maximize | Minimize: Switches the 4OS2 window to a 
  745.      maximized or minimized state at startup. Ignored in full-screen sessions. 
  746.      "Standard" means leave the window wherever OS/2 puts it. 
  747.  
  748.  
  749. ΓòÉΓòÉΓòÉ 2.10.2. Configuration Directives ΓòÉΓòÉΓòÉ
  750.  
  751. These directives control the way that 4OS2 operates.  Some can be changed with 
  752. the SETDOS command while 4OS2 is running. 
  753.  
  754.  AmPm= Yes | NO | Auto:  Sets the time display mode.  Yes displays times in 
  755.      12-hour format (e.g. in DIR and SELECT).  The default of No gives 24-hour 
  756.      time displays.  Auto sets the time display mode according to the current 
  757.      country code. 
  758.  BatchEcho= YES | No:  Sets the default batch ECHO mode.  Also see SETDOS /V. 
  759.  BeepFreq= nnnn (440):  Sets the default BEEP command frequency in Hz. To 
  760.      disable all 4OS2 error beeps set this or BeepLength to 0; 
  761.  BeepLength= nnnn (2):  Sets the default BEEP length in system clock ticks 
  762.      (approximately 1/18 of a second per tick). 
  763.  CursorIns= nnnn (100):  Sets the percentage of the character cell filled by 
  764.      the 4OS2 cursor in insert mode.  Also see SETDOS /S. 
  765.  CursorOver= nnnn (10):  Sets the percentage of the character cell filled by 
  766.      the 4OS2 cursor in overtype mode.  Also see SETDOS /S. 
  767.  CommandSep= c (&):  This is the character used to separate multiple commands 
  768.      on the same line.  Also see SETDOS /C. 
  769.  DescriptionMax= nnnn (40):  Sets the maximum file description length accepted 
  770.      by DESCRIBE; the range is 20 - 120 characters. 
  771.  EditMode= Insert | OVERSTRIKE:  Lets you start the command line editor in 
  772.      either insert or overstrike mode.  Also see SETDOS /M. 
  773.  EscapeChar= c (^):  Sets the character used to suppress the normal meaning of 
  774.      the following character.  Also see SETDOS /E. 
  775.  HelpBook= String (4OS2+CMDREF):  Tells the internal 4OS2 help command (F1 or 
  776.      HELP) which .INF files to use.  Filenames are separated by a +. Files 
  777.      should be in one of the directories specified by the BOOKSHELF environment 
  778.      variable. 
  779.  HistMin= nnnn (0):  Sets the minimum command length to save in the history 
  780.      list.  0 saves all commands, 300 disables all history saves. 
  781.  HistWinColor= Color:  Sets the default colors for the command line history 
  782.      window. 
  783.  HistWinHeight= nn (10):  Sets the height of the command line history window in 
  784.      lines, including the border. 
  785.  HistWinLeft= nn (50):  Sets the horizontal position of the left side of the 
  786.      command line history window.  The left edge of the screen is 0. 
  787.  HistWinTop= nn (0):  Sets the vertical position of the top of the command line 
  788.      history window.  The top of the screen is 0. 
  789.  HistWinWidth= nn (30):  Sets the width of the command line history window in 
  790.      characters, including the border. 
  791.  NoClobber= Yes | NO:  If set to Yes, prevents standard output redirection from 
  792.      overwriting an existing file, and requires the output file already exist 
  793.      for append redirection.  Also see SETDOS /N. 
  794.  ParameterChar= c ($):  Sets the character used to specify all or all remaining 
  795.      command line arguments (e.g. %$ or %2$). The default is $ in 4OS2 and & in 
  796.      4DOS. Also see SETDOS /P. 
  797.  ScreenRows= nnnn:  Sets the number of screen rows used by the video display. 
  798.      Normally, 4OS2 detects the screen size automatically, but if you have a 
  799.      non-standard display you may need to set it explicitly. Also see SETDOS 
  800.      /R. 
  801.  UpperCase= Yes | NO:  "Yes" specifies filenames should be displayed in the 
  802.      traditional upper-case by internal commands like COPY and DIR.  "No" 
  803.      allows the normal 4OS2 lower-case style.  Also see SETDOS /U. 
  804.  
  805.  
  806. ΓòÉΓòÉΓòÉ 2.10.3. Color Directives ΓòÉΓòÉΓòÉ
  807.  
  808. These directives control the colors that 4OS2 uses for its displays.  The color 
  809. format is: 
  810.  
  811.     [BRIght] [BLInk] fg ON bg [BORder bc]
  812.  
  813. Where fg is the foreground color, bg is the background color, and bc is the 
  814. border color.  The color names are: 
  815.  
  816.     Black         Blue          Green        Red
  817.     Magenta       Cyan          Yellow       White
  818.  
  819. The color names and the keywords BRIGHT, BLINK, and BORDER can be shortened to 
  820. three letters. 
  821.  
  822.  ColorDir= ext1 ext2 ...:colora;ext3 ext4 ... :colorb ... (none):  Sets the 
  823.      directory colors.  The format is the same as that used for the COLORDIR 
  824.      environment variable (see 4OS2 Internal Variables). 
  825.  ListColors= Color:  Sets the colors used by the LIST and SELECT commands. 
  826.  StdColors= Color:  Sets the standard colors to be used when CLS is used 
  827.      without a color specification, and for LIST and SELECT if ListColors is 
  828.      not used. 
  829.  
  830.  
  831. ΓòÉΓòÉΓòÉ 2.10.4. Key Mapping Directives ΓòÉΓòÉΓòÉ
  832.  
  833. The directives in this group allow you to change the keys used for 4OS2 command 
  834. line editing and other internal functions.  They take effect only inside 4OS2 
  835. itself and do not affect other programs (including the help system).  4OS2 
  836. processes all command line editing key assignments before looking for keystroke 
  837. aliases.  For example, if you assign Shift-F1 to HELP and also assign Shift-F1 
  838. to a key alias, the key alias will be ignored.  (Use the "Normal" directives -- 
  839. NormalKey, NormalEditKey, etc. -- to disable the preassigned function for a key 
  840. so it can be used for a keystroke alias.) 
  841.  
  842. There are three pre-mapped keys:  Tab and Shift-Tab (mapped to NextFile and 
  843. PrevFile respectively) and Ctrl-Bksp (mapped to DelWordRight).  If you need to 
  844. clear out these assignments so you can assign Tab, Shift-Tab, or Ctrl-Bksp to a 
  845. keystroke alias, use the ClearKeyMap directive described at the end of this 
  846. section. 
  847.  
  848. The format for a key name is:  [Prefix-]Keyname.  The prefix and key name must 
  849. be separated by a dash.  The prefix can be left out, or it can be any of the 
  850. following: 
  851.  
  852.     Alt     followed by A - Z, 0 - 9, F1 - F12, or Bksp
  853.     Ctrl    followed by A - Z, F1 - F12, Bksp, Enter,
  854.               Left, Right, Home, End, PgUp, PgDn, Ins, or Del
  855.     Shift   followed by F1 - F12 or Tab.
  856.  
  857. The possible key names are: 
  858.  
  859.     A - Z       Esc         Up          PgUp
  860.     0 - 9       Bksp        Down        PgDn
  861.     F1 - F12    Tab         Left        Home
  862.     Ins         Enter       Right       End
  863.     Del
  864.  
  865. General Input Keys 
  866.  
  867. These directives are effective whenever 4OS2 requests input from the keyboard, 
  868. including command line editing and the DESCRIBE, ESET, INPUT, LIST, and SELECT 
  869. commands. (Scrolling through the command history list is controlled by NextHist 
  870. and PrevHist (see below), not by the Up and Down directives below.) 
  871.  
  872.  Backspace= Key (Bksp):  Deletes the character to the left of the cursor. 
  873.  BeginLine= Key (Home):  Moves the cursor to the beginning of the line. 
  874.  Del = Key (Del):  Deletes the character at the cursor. 
  875.  DelToBeginning= Key (Ctrl-Home):  Deletes from the cursor to the start of the 
  876.      line. 
  877.  DelToEnd= Key (Ctrl-End):  Deletes from the cursor to the end of the line. 
  878.  DelWordLeft= Key (Ctrl-L):  Deletes the word to the left of the cursor. 
  879.  DelWordRight= Key (Ctrl-R, Ctrl-Bksp):  Deletes the word to the right of the 
  880.      cursor.  See ClearKeyMap at the end of this section if you need to remove 
  881.      the mapping of Ctrl-Bksp to DelWordRight. 
  882.  Down= Key (Down):  Scrolls the display down one line in LIST; moves the cursor 
  883.      down one line in SELECT and in the command history window. 
  884.  EndLine= Key (End):  Moves the cursor to the end of the line. 
  885.  EraseLine= Key (Esc):  Deletes the entire line. 
  886.  ExecLine= Key (Enter):  Executes or accepts a line. 
  887.  Ins = Key (Ins):  Toggles insert / overstrike mode during line editing. 
  888.  Left= Key (Left):  Moves the cursor left one character; moves the display left 
  889.      8 columns in LIST. 
  890.  NormalKey= Key (none):  Deassigns a general input key in order to disable the 
  891.      usual meaning of the key within 4OS2 and / or make it available for 
  892.      keystroke aliases.  This will cause 4OS2 to treat the keystroke as a 
  893.      "normal" key with no special function. 
  894.  Right= Key (Right):  Moves the cursor right one character; scrolls the display 
  895.      right 8 columns in LIST. 
  896.  Up  = Key (Up):  Scrolls the display up one line in LIST; moves the cursor up 
  897.      one line in SELECT and in the command history window. 
  898.  WordLeft= Key (Ctrl-Left):  Moves the cursor left one word; scrolls the 
  899.      display left 40 columns in LIST. 
  900.  WordRight= Key (Ctrl-Right):  Moves the cursor right one word; scrolls the 
  901.      display right 40 columns in LIST. 
  902.  
  903.  Command Line Editing Keys 
  904.  
  905.  The following directives apply only to command line editing (see Command Line 
  906.  Editing).  They are only effective at the 4OS2 prompt. 
  907.  
  908.  AddFile= Key (F10):  Keeps the current filename completion entry and inserts 
  909.      the next matching name. 
  910.  CommandEscape= Key (Alt-255):  Allows direct entry of a keystroke that would 
  911.      normally be interpreted as an editor command. 
  912.  DelHistory= Key (Ctrl-D):  Deletes the displayed history list entry and 
  913.      displays the previous entry. 
  914.  EndHistory= Key (Ctrl-E):  Displays the last history list entry. 
  915.  Help= Key (F1):  Invokes the 4OS2 HELP facility. 
  916.  NextFile= Key (F9, Tab):  Gets the next matching filename. See ClearKeyMap at 
  917.      the end of this section if you need to remove the mapping of Tab to 
  918.      NextFile. 
  919.  NextHistory= Key (Down):  Recalls the next command from the command history. 
  920.  NormalEditKey= Key (none):  Deassigns a command line editing key in order to 
  921.      disable the usual meaning of the key while editing a command line and / or 
  922.      make it available for keystroke aliases.  This will cause 4OS2 to treat 
  923.      the keystroke as a "normal" key with no special function. 
  924.  PrevFile= Key (F8, Shift-Tab):  Gets the previous matching filename. See 
  925.      ClearKeyMap at the end of this section if you need to remove the mapping 
  926.      of Shift-Tab to PrevFile. 
  927.  PrevHistory= Key (Up):  Recalls the previous command from the command history. 
  928.  SaveHistory= Key (Ctrl-K):  Saves the command line in the history list without 
  929.      executing it. 
  930.  
  931.  History Window Keys 
  932.  
  933.  HistWinBegin= Key (Ctrl-PgUp):  Moves to the first line of the history when in 
  934.      the history window. 
  935.  HistWinEdit= Key (Ctrl-Enter):  Moves a line from the history window to the 
  936.      prompt for editing. 
  937.  HistWinEnd= Key (Ctrl-PgDn):  Moves to the last line of the history when in 
  938.      the history window. 
  939.  HistWinExec= Key (Enter):  Executes the selected line in the history window. 
  940.  HistWinOpen= Key (PgUp):  Brings up the history window while at the command 
  941.      line. 
  942.  NormalHWinKey= Key (none):  Deassigns a history window key in order to disable 
  943.      the usual meaning of the key within the history window.  This will cause 
  944.      4OS2 to treat the keystroke as a "normal" key with no special function. 
  945.  
  946.  LIST Keys 
  947.  
  948.  These directives control the keystrokes used within the LIST command. 
  949.  
  950.  ListFind= Key (F):  Prompts and searches for a string. 
  951.  ListHighBit= Key (H):  Toggles LIST's "strip high bit" option, which can aid 
  952.      in displaying files from certain word processors. 
  953.  ListNext= Key (N):  Finds the next matching string. 
  954.  ListPrint= Key (P):  Prints the file on LPT1. 
  955.  ListWrap= Key (W):  Toggles LIST's wrap option on and off.  The wrap option 
  956.      wraps text at the right margin. 
  957.  NormalListKey= Key (none):  Deassigns a LIST key in order to disable the usual 
  958.      meaning of the key within LIST.  This will cause 4OS2 to treat the 
  959.      keystroke as a "normal" key with no special function. 
  960.  
  961.  ClearKeyMap Directive 
  962.  
  963.  This directive allows you to start with an empty key map. 
  964.  
  965.  ClearKeyMap:  Clears all current key mappings. ClearKeyMap is a special 
  966.      directive which has no value or "=" after it.  Use ClearKeyMap if you want 
  967.      to make one of the keys in 4OS2's default map (Tab, Shift-Tab, or 
  968.      Ctrl-Bksp) available for a keystroke alias; or in the [Secondary] section 
  969.      to clear key mappings inherited from the primary shell. ClearKeyMap should 
  970.      appear before any other key mapping directives.  If you only need to clear 
  971.      some of the default mappings, use ClearKeyMap, then recreate the mappings 
  972.      you want to retain (e.g. with "Tab=NextFile", etc.). 
  973.  
  974.  
  975. ΓòÉΓòÉΓòÉ 2.10.5. Example ΓòÉΓòÉΓòÉ
  976.  
  977. The following example gives you an idea of the types of things that can be done 
  978. with the 4OS2.INI file.  The comments on each directive explain what it does. 
  979.  
  980.     History = 1024         ; set history size
  981.     BatchEcho = No         ; default is ECHO OFF
  982.     EditMode = Insert      ; editor in insert mode
  983.     CursorO = 100          ; overstrike cursor 100%
  984.     CursorI = 10           ; insert cursor 10%
  985.     ListFind = S           ; use "S" to search in LIST
  986.     ListNext = A           ; use "A" to search again in LIST
  987.  
  988.  
  989. ΓòÉΓòÉΓòÉ 3. 4OS2 Commands ΓòÉΓòÉΓòÉ
  990.  
  991. The 4OS2 commands are described in detail in this section.  The commands are 
  992. arranged alphabetically, and each includes examples to help you learn to use 
  993. the commands. 
  994.  
  995.  
  996. ΓòÉΓòÉΓòÉ 3.1. 4OS2 - 4OS2 command processor ΓòÉΓòÉΓòÉ
  997.  
  998. SYNTAX     (External OS/2) 
  999.  
  1000. [[d:]path]4OS2 [/C /K /L /Q /S][@inifile][command ...]
  1001.  
  1002. PURPOSE 
  1003.  
  1004. Start a new copy of the 4OS2 command processor. 
  1005.  
  1006. COMMENTS 
  1007.  
  1008. 4OS2 replaces CMD.EXE, the default command processor provided with OS/2. The 
  1009. 4OS2 options are: 
  1010.  
  1011.     /C            Execute the command following the /C, and automatically 
  1012.                   return to the previous command processor. 
  1013.  
  1014.     /K            Execute the command following the /K, but do not return to 
  1015.                   the previous command processor.  4OS2 defaults to /K if /C is 
  1016.                   not specified. 
  1017.  
  1018.     /LA           Use local alias list.  4OS2 normally shares its alias list 
  1019.                   across all sessions; specifying /LA shares it only among 
  1020.                   processes in the same session. 
  1021.  
  1022.     /LH           Use local history list.  4OS2 normally shares its history 
  1023.                   list across all sessions; specifying /LH shares it only among 
  1024.                   processes in the same session. 
  1025.  
  1026.     /Q            Don't echo redirected standard input. 
  1027.  
  1028.     /S            Don't install a ^C signal handler. 
  1029.  
  1030.     @inifile      The 4OS2.INI file specification. 
  1031.  
  1032.     command       The command to execute. 
  1033.  
  1034.  EXAMPLE 
  1035.  
  1036.  Start 4OS2 with local alias and history lists, using the 4OS2.INI file in 
  1037.  D:\4OS2: 
  1038.  
  1039.       4OS2 @D:\4OS2\4OS2.INI /LA /LH
  1040.  
  1041.  
  1042. ΓòÉΓòÉΓòÉ 3.2. ? - Display internal commands ΓòÉΓòÉΓòÉ
  1043.  
  1044. SYNTAX     (Internal 4OS2) 
  1045.  
  1046. ?
  1047.  
  1048. PURPOSE 
  1049.  
  1050. Display the internal commands.  Commands disabled with SETDOS /I will not be 
  1051. displayed. 
  1052.  
  1053.  
  1054. ΓòÉΓòÉΓòÉ 3.3. ALIAS - Display / set aliases ΓòÉΓòÉΓòÉ
  1055.  
  1056. SYNTAX     (Internal 4OS2) 
  1057.  
  1058. ALIAS [/P] [/R [d:][path]filename...] [name[=][value]]
  1059.  
  1060. PURPOSE 
  1061.  
  1062. Load or display the alias list, or define name as a substitute for value. 
  1063.  
  1064. COMMENTS 
  1065.  
  1066. Aliases are useful as a means of executing a complex series of commands with a 
  1067. few keystrokes.  Aliases can also be used as very fast in-memory batch files, 
  1068. and will run much faster than disk-based batch files. 
  1069.  
  1070. 4OS2 supports two types of aliases; command aliases (where the alias is 
  1071. substituted for the first argument on the command line), and "keystroke 
  1072. aliases", where the command line editor will immediately substitute the alias 
  1073. when the key is pressed. 
  1074.  
  1075. Keystroke alias names are composed of an @ followed by the key name.  You can 
  1076. add a carriage return to a key alias by ending the alias with a ^^r (^ is the 
  1077. 4OS2 escape character) if defined at the command line or in a batch file, or ^r 
  1078. if defined in an ALIAS /R file.  The valid key names are the same as those 
  1079. listed in the section on Key Names in Extended Key Codes. 
  1080.  
  1081. If you only specify "name", ALIAS displays the current alias value for "name". 
  1082. Otherwise, ALIAS assigns the command(s) in "value" to "name". "Name" can now be 
  1083. used as if it were a built-in or external command.  If you don't specify any 
  1084. arguments, ALIAS displays the current alias list. 
  1085.  
  1086. "Name" is limited to no more than 80 characters, and "value" to no more than 
  1087. 255 characters. 
  1088.  
  1089. The ALIAS options are: 
  1090.  
  1091.     /P      Pause after displaying each page and wait for a key to be pressed. 
  1092.  
  1093.     /R      Load an alias list from a file.  This is much faster than loading 
  1094.             aliases from a batch file.  The file is in the same format as the 
  1095.             ALIAS display, so ALIAS /R can accept as input a file generated by 
  1096.             redirecting ALIAS output.  You can add comments to an alias file by 
  1097.             starting the comment line with a colon (:). 
  1098.  
  1099.  For example, the following commands will save the aliases to a file, and then 
  1100.  reload them from that file: 
  1101.  
  1102.       alias > alist
  1103.       alias /r alist
  1104.  
  1105.  (You can load aliases from multiple files by listing all the filenames after 
  1106.  the /R.) 
  1107.  
  1108.  When defining aliases at the command line, back quotes must be used around the 
  1109.  alias arguments that contain multiple commands or variable references (%2, 
  1110.  %2$, etc.) to prevent premature expansion.  Back quotes should NOT be used 
  1111.  when defining aliases in a file to be read with ALIAS /R. 
  1112.  
  1113.  Aliases may be nested; i.e., an alias can refer to another alias, but they 
  1114.  cannot refer back to themselves (a=b=a).  You can stop alias expansion by 
  1115.  prefacing the alias with an asterisk (*).  This also allows an alias to refer 
  1116.  to a command of the same name (see below for an example). 
  1117.  
  1118.  Alias names can be truncated by including an asterisk (*) in the name. 
  1119.  
  1120.  To edit an alias, use ESET; to remove an alias, use UNALIAS. 
  1121.  
  1122.  For more information on aliases (including the use of variables), see the 
  1123.  Aliases section in the printed manual, and the sample file ALIASES distributed 
  1124.  with 4OS2. 
  1125.  
  1126.  See also ESET and UNALIAS. 
  1127.  
  1128.  EXAMPLES 
  1129.  
  1130.  Define D as an alias for DIR /AP: 
  1131.  
  1132.       alias d dir /ap
  1133.  
  1134.  Rename the LIST command to DISPLAY, and alias LIST to an external program: 
  1135.  
  1136.       alias display *list
  1137.       alias list c:\util\list.com
  1138.  
  1139.  The following examples show the use of alias arguments: 
  1140.  
  1141.       alias zap `erase %$ & chkdsk & dir /w`
  1142.       alias reverse `echo %5 %4 %3 %2 %1`
  1143.  
  1144.  The following keystroke alias will insert a "dir /2 /v /p " on the command 
  1145.  line when the Alt-F1 key is pressed: 
  1146.  
  1147.       alias @Alt-F1 `dir /2 /v /p `
  1148.  
  1149.  The same alias set up to execute immediately when Alt-F1 is pressed. 
  1150.  
  1151.       alias @Alt-F1 `dir /2 /v /p^r`
  1152.  
  1153.  
  1154. ΓòÉΓòÉΓòÉ 3.4. ATTRIB - Display / set file attributes ΓòÉΓòÉΓòÉ
  1155.  
  1156. SYNTAX     (Internal 4OS2) 
  1157.  
  1158. ATTRIB [/D /P /Q /S -|+[AHRS]] [d:][path]filename...
  1159.  
  1160. PURPOSE 
  1161.  
  1162. Change the file or subdirectory attributes. 
  1163.  
  1164. COMMENTS 
  1165.  
  1166. The ATTRIB options are: 
  1167.  
  1168.     /D      Also modify subdirectory attributes 
  1169.     /P      Pause after displaying each page 
  1170.     /Q      Quiet mode - don't display filenames 
  1171.     /S      Modify files in the current directory and its subdirectories 
  1172.     +A      Set the archive attribute 
  1173.     -A      Clear the archive attribute 
  1174.     +H      Set the hidden attribute 
  1175.     -H      Clear the hidden attribute 
  1176.     +R      Set the read-only attribute 
  1177.     -R      Clear the read-only attribute 
  1178.     +S      Set the system file attribute 
  1179.     -S      Clear the system file attribute 
  1180.  
  1181.  If you don't specify the /D option, ATTRIB only modifies file attributes. If 
  1182.  you don't specify any attributes to change, ATTRIB displays the current file 
  1183.  attributes.  You can also display the file attributes using the /T option in 
  1184.  DIR. 
  1185.  
  1186.  ATTRIB will preserve the previous file attributes and change only the 
  1187.  specified attributes.  New attribute values are allowed between filenames; 
  1188.  otherwise ATTRIB uses the same attributes specified for the previous file(s). 
  1189.  You cannot modify the directory or volume label attributes. 
  1190.  
  1191.  EXAMPLES 
  1192.  
  1193.  Set the read-only and hidden attributes for the file MEMO: 
  1194.  
  1195.       attrib +rh memo
  1196.  
  1197.  Set the archive attribute (file has been modified) for MEMO and change 
  1198.  TEXT.COM to system and not modified: 
  1199.  
  1200.       attrib +a memo +s -a test.com
  1201.  
  1202.  
  1203. ΓòÉΓòÉΓòÉ 3.5. BEEP - Beep the speaker ΓòÉΓòÉΓòÉ
  1204.  
  1205. SYNTAX     (Internal 4OS2) 
  1206.  
  1207. BEEP [frequency [duration] ...]
  1208.  
  1209. PURPOSE 
  1210.  
  1211. Beep the speaker. 
  1212.  
  1213. COMMENTS 
  1214.  
  1215. BEEP is normally used in batch files to signal that an operation has been 
  1216. completed, or that the computer needs attention (for example, to change disks). 
  1217. Because BEEP allows you to specify the frequency and duration, you can use it 
  1218. to play simple music.  You can specify multiple frequency and duration pairs on 
  1219. the command line. 
  1220.  
  1221. The frequency is specified in Hertz, and the duration in 1/18th second 
  1222. intervals.  No sound will be generated for frequencies less than 37 Hz, 
  1223. allowing you to insert short delays.  The default value for frequency is 440 
  1224. Hz; the default value for duration is 2. 
  1225.  
  1226. The following table gives the frequency values for a five octave range (middle 
  1227. C is 262 Hz): 
  1228.  
  1229.     ΓòöΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòñΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòñΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòñΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòñΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòñΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòù
  1230.     Γòæ C      Γöé  131  Γöé  262  Γöé  523  Γöé  1046  Γöé  2093 Γòæ
  1231.     Γòæ C#/Db  Γöé  139  Γöé  277  Γöé  554  Γöé  1108  Γöé  2217 Γòæ
  1232.     Γòæ D      Γöé  147  Γöé  294  Γöé  587  Γöé  1175  Γöé  2349 Γòæ
  1233.     Γòæ D#/Eb  Γöé  156  Γöé  311  Γöé  622  Γöé  1244  Γöé  2489 Γòæ
  1234.     Γòæ E      Γöé  165  Γöé  330  Γöé  659  Γöé  1318  Γöé  2637 Γòæ
  1235.     Γòæ F      Γöé  175  Γöé  349  Γöé  698  Γöé  1397  Γöé  2794 Γòæ
  1236.     Γòæ F#/Gb  Γöé  185  Γöé  370  Γöé  740  Γöé  1480  Γöé  2960 Γòæ
  1237.     Γòæ G      Γöé  196  Γöé  392  Γöé  784  Γöé  1568  Γöé  3136 Γòæ
  1238.     Γòæ G#/Ab  Γöé  208  Γöé  415  Γöé  831  Γöé  1662  Γöé  3322 Γòæ
  1239.     Γòæ A      Γöé  220  Γöé  440  Γöé  880  Γöé  1760  Γöé  3520 Γòæ
  1240.     Γòæ A#/Bb  Γöé  233  Γöé  466  Γöé  932  Γöé  1866  Γöé  3729 Γòæ
  1241.     Γòæ B      Γöé  248  Γöé  494  Γöé  988  Γöé  1973  Γöé  3951 Γòæ
  1242.     ΓòÜΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòºΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòºΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòºΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòºΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòºΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓò¥
  1243.  
  1244. EXAMPLE 
  1245.  
  1246. The following batch file fragment runs the program DEMO, plays a few notes, and 
  1247. waits for you to press a key: 
  1248.  
  1249.     demo
  1250.     beep 440 4 587 2 1040 6
  1251.     pause Finished with the demo - press a key to continue
  1252.  
  1253.  
  1254. ΓòÉΓòÉΓòÉ 3.6. CALL - Call a batch file ΓòÉΓòÉΓòÉ
  1255.  
  1256. SYNTAX     (Internal 4OS2) 
  1257.  
  1258. CALL [d:][path]filename
  1259.  
  1260. PURPOSE 
  1261.  
  1262. Call a secondary batch file. 
  1263.  
  1264. COMMENTS 
  1265.  
  1266. CALL allows batch files to call other batch files (batch file nesting) without 
  1267. invoking a secondary copy of the command processor.  The calling batch file is 
  1268. suspended while the called batch file runs.  When the called batch file 
  1269. finishes, the calling batch file resumes execution at the next command.  If you 
  1270. execute a batch file from another batch file without using CALL, the first 
  1271. batch file is terminated before the second one starts. 
  1272.  
  1273. The current ECHO state will be inherited by a called batch file. 
  1274.  
  1275. See also CANCEL and QUIT. 
  1276.  
  1277. EXAMPLE 
  1278.  
  1279. The following batch file fragment compares an input line to "wp" and calls a 
  1280. secondary batch file if it matches: 
  1281.  
  1282.     input Enter your choice:  %%option
  1283.     if "%option" == "wp" call wp
  1284.  
  1285.  
  1286. ΓòÉΓòÉΓòÉ 3.7. CANCEL - Quit all batch files ΓòÉΓòÉΓòÉ
  1287.  
  1288. SYNTAX     (Internal 4OS2) 
  1289.  
  1290. CANCEL [value]
  1291.  
  1292. PURPOSE 
  1293.  
  1294. Terminate batch processing. 
  1295.  
  1296. COMMENTS 
  1297.  
  1298. The CANCEL command will end all batch file processing, regardless of the batch 
  1299. nesting level.  (Use QUIT to end a nested batch file and return to the previous 
  1300. batch file.)  If you enter a value, CANCEL will set the ERRORLEVEL to that 
  1301. value.  The value also affects the internal variable %_?, and the conditional 
  1302. command separators && and ||. 
  1303.  
  1304. You can CANCEL at any point in a batch file. 
  1305.  
  1306. See also CALL and QUIT. 
  1307.  
  1308. EXAMPLE 
  1309.  
  1310. The following batch file fragment compares an input line to "end" and 
  1311. terminates all batch file processing if it matches: 
  1312.  
  1313.     input Enter your choice:  %%option
  1314.     if "%option" == "end" cancel
  1315.  
  1316.  
  1317. ΓòÉΓòÉΓòÉ 3.8. CD or CHDIR - Change directory ΓòÉΓòÉΓòÉ
  1318.  
  1319. SYNTAX     (Internal 4OS2) 
  1320.  
  1321. CD [[d:][pathname]
  1322. CHDIR [[d:][pathname]
  1323.  
  1324. PURPOSE 
  1325.  
  1326. Display or change the current directory. 
  1327.  
  1328. COMMENTS 
  1329.  
  1330. Entering CD with no argument or only a drive name will display the current 
  1331. directory.  Entering CD and a pathname will change the current directory. 
  1332.  
  1333. If CD can't change to the specified directory, it will look for the CDPATH (or 
  1334. _CDPATH) environment variable.  CD will append the specified directory name to 
  1335. each directory in CDPATH and attempt to change to that directory, until the 
  1336. first match or the end of the CDPATH argument. 
  1337.  
  1338. The previous directory is saved on each CD, and you can switch back to it with 
  1339. "CD -".  You can switch between two directories by repeatedly entering "CD -". 
  1340. Note that the saved directory is the same for both CD and CDD. 
  1341.  
  1342. You can change directories by pressing ^PgUp at the prompt, which will display 
  1343. a popup window of the most recent directory changes; you can select a directory 
  1344. and switch to it by pressing Enter. 
  1345.  
  1346. You can change to the parent directory with "CD ..".  You can also go up one 
  1347. additional directory level with each additional ".".  For example, "CD ...." 
  1348. will go up three directory levels. 
  1349.  
  1350. Every disk drive on the system has its own current directory.  Specifying both 
  1351. a drive and a directory in the CD command will change the current directory on 
  1352. the specified drive, but will not change the default drive. Use CDD to change 
  1353. both the drive and directory. 
  1354.  
  1355. See also %CDPATH, CDD, and PUSHD. 
  1356.  
  1357. EXAMPLES 
  1358.  
  1359. Change to the subdirectory C:\FINANCE\MYFILES: 
  1360.  
  1361.     cd \finance\myfiles
  1362.  
  1363. Change the default directory on drive A: 
  1364.  
  1365.     cd a:\utility
  1366.  
  1367. Set the CDPATH environment variable and then CD to a directory called DOCS (CD 
  1368. will first attempt to change to DOCS in the current directory, then C:\DOCS, 
  1369. then C:\OS\DOCS, etc.): 
  1370.  
  1371.     set cdpath=c:\;c:\os;c:\util;c:\wp
  1372.     cd docs
  1373.  
  1374.  
  1375. ΓòÉΓòÉΓòÉ 3.9. CDD - Change disk and directory ΓòÉΓòÉΓòÉ
  1376.  
  1377. SYNTAX     (Internal 4OS2) 
  1378.  
  1379. CDD [d:]pathname
  1380.  
  1381. PURPOSE 
  1382.  
  1383. Change the current disk drive and directory. 
  1384.  
  1385. COMMENTS 
  1386.  
  1387. CDD is similar to CD, except it can also change the default disk drive. 
  1388.  
  1389. To start at the root directory, start the pathname with a backslash (\). To 
  1390. start at the parent directory, start the pathname with two periods (..). All 
  1391. other pathnames start at the current directory. 
  1392.  
  1393. If CDD can't change to the specified directory, it will look for the CDPATH (or 
  1394. _CDPATH) environment variable.  CDD will append the specified directory name to 
  1395. each directory in CDPATH and attempt to change to that directory, until the 
  1396. first match or the end of the CDPATH argument. 
  1397.  
  1398. The previous directory is saved on each CDD, and you can switch back to it with 
  1399. "CDD -".  You can switch between two directories by repeatedly entering "CDD 
  1400. -".  Note that the saved directory is the same for both CDD and CD. 
  1401.  
  1402. You can change directories by pressing ^PgUp at the prompt, which will display 
  1403. a popup window of the most recent directory changes; you can select a directory 
  1404. and switch to it by pressing Enter. 
  1405.  
  1406. You can change to the parent directory with "CD ..".  You can also go up one 
  1407. additional directory level with each additional ".".  For example, "CD ...." 
  1408. will go up three directory levels. 
  1409.  
  1410. See also %CDPATH, CD and PUSHD. 
  1411.  
  1412. EXAMPLES 
  1413.  
  1414. Change to the subdirectory C:\WP: 
  1415.  
  1416.     cdd c:\wp
  1417.  
  1418. Set the CDPATH environment variable and then CDD to a directory called DOCS 
  1419. (CDD will first attempt to change to DOCS in the current directory, then 
  1420. C:\DOCS, then C:\OS\DOCS, etc.): 
  1421.  
  1422.     set cdpath=c:\;c:\os;c:\util;c:\wp
  1423.     cdd docs
  1424.  
  1425.  
  1426. ΓòÉΓòÉΓòÉ 3.10. CHCP - Change code page ΓòÉΓòÉΓòÉ
  1427.  
  1428. SYNTAX     (Internal 4OS2) 
  1429.  
  1430. CHCP [n]
  1431.  
  1432. PURPOSE 
  1433.  
  1434. Display or change the current system code page. 
  1435.  
  1436. COMMENTS 
  1437.  
  1438. Code page switching allows you to select different character sets for language 
  1439. support. 
  1440.  
  1441. Before using CHCP, you must have DEVINFO= and CODEPAGE= statements in 
  1442. CONFIG.SYS for the specified code page. 
  1443.  
  1444. CHCP accepts one of the two prepared system code pages.  An error message is 
  1445. displayed if a code page is selected that has not been prepared. 
  1446.  
  1447. Entering CHCP with no argument displays the active code page. 
  1448.  
  1449. The code pages supported by OS/2 are: 
  1450.  
  1451.     437   United States
  1452.     850   Multilingual (Latin I)
  1453.     852   Slavic (Latin II)
  1454.     860   Portuguese
  1455.     863   Canadian-French
  1456.     865   Nordic
  1457.  
  1458. See your OS/2 manual for more information on CHCP and code page switching. 
  1459.  
  1460. EXAMPLES 
  1461.  
  1462. Display the current code page: 
  1463.  
  1464.     chcp
  1465.  
  1466. Set the code page to multilingual: 
  1467.  
  1468.     chcp 850
  1469.  
  1470.  
  1471. ΓòÉΓòÉΓòÉ 3.11. CLS - Clear screen ΓòÉΓòÉΓòÉ
  1472.  
  1473. SYNTAX     (Internal 4OS2) 
  1474.  
  1475. CLS [[bright] [blink] fg ON bg [BORDER fg]]
  1476.  
  1477. PURPOSE 
  1478.  
  1479. Clear the video display, optionally to the specified colors. 
  1480.  
  1481. COMMENTS 
  1482.  
  1483. CLS clears the display and moves the cursor to the upper left corner.  fg is 
  1484. the foreground color, bg the background color.  Only the first three characters 
  1485. of the color name and attributes ("bright" and "blink") are required.  You can 
  1486. set the default colors in the 4OS2.INI file. 
  1487.  
  1488. The available colors are: 
  1489.  
  1490.     Black      Blue      Green      Red
  1491.     Magenta    Cyan      Yellow     White
  1492.  
  1493. CLS is normally used in batch files to clear the screen before displaying text. 
  1494.  
  1495. See also COLOR and 4OS2.INI Color Directives. 
  1496.  
  1497. EXAMPLES 
  1498.  
  1499. Clear the display: 
  1500.  
  1501.     cls
  1502.  
  1503. Clear the display to a blue background, and set white characters as the new 
  1504. default: 
  1505.  
  1506.     cls white on blue
  1507.  
  1508.  
  1509. ΓòÉΓòÉΓòÉ 3.12. COLOR - Set screen colors ΓòÉΓòÉΓòÉ
  1510.  
  1511. SYNTAX     (Internal 4OS2) 
  1512.  
  1513. COLOR [[bright] [blink] fg ON bg [BORDER fg]]
  1514.  
  1515. PURPOSE 
  1516.  
  1517. Set the screen display colors. 
  1518.  
  1519. COMMENTS 
  1520.  
  1521. fg is the foreground color, bg the background color.  Only the first three 
  1522. characters of the color name and attributes ("bright" and "blink") are 
  1523. required. 
  1524.  
  1525. The available colors are: 
  1526.  
  1527.     Black      Blue      Green      Red
  1528.     Magenta    Cyan      Yellow     White
  1529.  
  1530. See also CLS. 
  1531.  
  1532. EXAMPLE 
  1533.  
  1534. Set the default screen colors to bright white text on a blue background: 
  1535.  
  1536.     color bright white on blue
  1537.  
  1538.  
  1539. ΓòÉΓòÉΓòÉ 3.13. COPY - Copy files ΓòÉΓòÉΓòÉ
  1540.  
  1541. SYNTAX     (Internal 4OS2) 
  1542.  
  1543. COPY [d:][path]filename[+]...[/A /B] [[d:][path]filename]
  1544.     [/A /B /C /F /M /N /P /Q /R /S /U /V]
  1545.  
  1546. PURPOSE 
  1547.  
  1548. Copy or append one or more files. 
  1549.  
  1550. COMMENTS 
  1551.  
  1552. 4OS2 allows you to copy several unrelated files to a target directory with a 
  1553. single COPY command.  If there are two or more arguments on the command line, 
  1554. COPY assumes the last argument is the target.  If there is only one argument, 
  1555. the target is assumed to be the current directory. 
  1556.  
  1557. The plus (+) tells COPY to append two or more files to a single target file. 
  1558. If you don't specify a target, COPY will append each subsequent file to the 
  1559. first file. 
  1560.  
  1561. If you specify more than one source file, and the target is NOT a directory, 
  1562. COPY will automatically append the files to the target. 
  1563.  
  1564. The /A(SCII) or /B(inary) options apply to the preceding filename and to all 
  1565. subsequent filenames on the command line until the filename preceding another 
  1566. /A or /B, if any.  All other options apply to all filenames on the command 
  1567. line. 
  1568.  
  1569. The COPY options are: 
  1570.  
  1571.     /A      If used with a source filename, COPY will copy the file up to, but 
  1572.             not including, the first ^Z character in the file.  If you use /A 
  1573.             with a target filename, COPY will add a ^Z to the end of the file. 
  1574.             COPY defaults to /A when appending files. 
  1575.  
  1576.     /B      If used with a source filename, COPY will copy the entire file. 
  1577.             Using /B with a target filename prevents COPY from appending a ^Z 
  1578.             to the target file.  COPY defaults to /B for normal file copies. 
  1579.  
  1580.     /C      Copy only those files where the target exists and is older than the 
  1581.             source (see /U). 
  1582.  
  1583.     /F      Fail the copy if the source file has extended attributes and the 
  1584.             target file system doesn't support extended attributes. 
  1585.  
  1586.     /H      Copy hidden and system files too. 
  1587.  
  1588.     /M      Copy only those files with the archive bit set (see also ATTRIB). 
  1589.             The archive bit will NOT be cleared after copying. 
  1590.  
  1591.     /N      Do everything except actually perform the copy (for testing what 
  1592.             the result of the COPY would be). 
  1593.  
  1594.     /P      Confirm each file copy (Y or N).  An N response will skip that 
  1595.             particular file. 
  1596.  
  1597.     /Q      Don't display filenames as they are copied. 
  1598.  
  1599.     /R      Prompt before overwriting an existing file. 
  1600.  
  1601.     /S      Copy subdirectories - the target must be a directory (COPY will 
  1602.             create it if it doesn't exist).  COPY will copy each subdirectory 
  1603.             to a matching subdirectory of the target. 
  1604.  
  1605.     /U      Copy only those source files that are newer than a matching target 
  1606.             file, or where a matching target file doesn't exist (see /C). 
  1607.  
  1608.     /V      Verify each disk write.  This is the same as executing the VERIFY 
  1609.             ON command, but is only active during the COPY. 
  1610.  
  1611.  See also MOVE. 
  1612.  
  1613.  EXAMPLES 
  1614.  
  1615.  Copy the files MEMO1 and PROJECT8.WKS to the root directory on drive A: 
  1616.  
  1617.       copy memo1 project8.wks a:\
  1618.  
  1619.  Append the files MEMO1, MEMO2, and MEMO3 and store the result in BIGMEMO: 
  1620.  
  1621.       copy memo1+memo2+memo3 bigmemo
  1622.  
  1623.  Copy only those files in the root directory on drive A that are newer than the 
  1624.  matching files in the current directory, or that don't exist in the current 
  1625.  directory: 
  1626.  
  1627.       copy /u a:\*.* c:\*.*
  1628.  
  1629.  Copy files from the root directory on drive A to the current directory, but 
  1630.  prompt before overwriting existing files: 
  1631.  
  1632.       copy /r a:\*.*
  1633.  
  1634.  Copy a downloadable font file to the printer in binary mode: 
  1635.  
  1636.       copy myfont.dat lpt1: /b
  1637.  
  1638.  
  1639. ΓòÉΓòÉΓòÉ 3.14. DATE - Set or display date ΓòÉΓòÉΓòÉ
  1640.  
  1641. SYNTAX     (Internal 4OS2) 
  1642.  
  1643. DATE [mm-dd-yy]
  1644.  
  1645. PURPOSE 
  1646.  
  1647. Display and (optionally) change the system date. 
  1648.  
  1649. COMMENTS 
  1650.  
  1651. If you don't enter any parameters, DATE will display the current system date 
  1652. and time, and prompt for the new date.  Press ENTER if you don't wish to change 
  1653. the date, otherwise enter the new date. 
  1654.  
  1655. The format for the date entry depends on the country code defined in CONFIG.SYS 
  1656. or by the CHCP command.  The default format is U.S. (mm-dd-yy).  The European 
  1657. format is dd-mm-yy; the Japanese is yy-mm-dd. 
  1658.  
  1659. The parameters for the DATE command are: 
  1660.  
  1661.     mm      Month (1 - 12) 
  1662.     dd      Day (1 - 31) 
  1663.     yy      Year (80 - 199 or 1980 - 2099) 
  1664.  
  1665.  You can use hyphens, slashes, or periods to separate the month, day, and year 
  1666.  entries. 
  1667.  
  1668.  See also TIME. 
  1669.  
  1670.  EXAMPLES 
  1671.  
  1672.  Enter the date from the command line: 
  1673.  
  1674.       date 12/25/89
  1675.  
  1676.  To be prompted for the date: 
  1677.  
  1678.       date
  1679.  
  1680.  
  1681. ΓòÉΓòÉΓòÉ 3.15. DEL or ERASE - Delete files ΓòÉΓòÉΓòÉ
  1682.  
  1683. SYNTAX     (Internal 4OS2) 
  1684.  
  1685. DEL [/F /N /P /Q /S /X /Y /Z] [d:][path]filename...
  1686. ERASE [/F /N /P /Q /S /X /Y /Z] [d:][path]filename...
  1687.  
  1688. PURPOSE 
  1689.  
  1690. Erase the specified file(s) from the disk. 
  1691.  
  1692. COMMENTS 
  1693.  
  1694. The DEL options are: 
  1695.  
  1696.     /F      [4OS2/32 only]  Delete the specified file(s) without making copies 
  1697.             in the DELDIR directory.  Caution:  Using DEL /F will make the 
  1698.             deleted files unrecoverable! 
  1699.  
  1700.     /N      Do everything except actually delete the file(s) (for testing what 
  1701.             the result of a DEL would be). 
  1702.  
  1703.     /P      Confirm file deletion for each file. 
  1704.  
  1705.     /Q      Don't display filenames as they are deleted. 
  1706.  
  1707.     /S      Delete matching files in the subdirectories. 
  1708.  
  1709.     /X      Remove empty subdirectories after deleting (use with /S). 
  1710.  
  1711.     /Y      The reverse of /P - it assumes a Y response to everything, 
  1712.             including deleting an entire subdirectory.  Use with caution! 
  1713.  
  1714.     /Z      Delete all files, including read-only, hidden and system files. 
  1715.  
  1716.  If you enter a subdirectory name, or a filename composed only of wildcards, 
  1717.  DEL asks for confirmation (Y or N), unless you specified the /Y(es) option. If 
  1718.  you respond with a Y, DEL will delete all the files in that subdirectory 
  1719.  (except for hidden, system, and read-only files). 
  1720.  
  1721.  If you do not use the /Q(uiet) option, DEL displays a count of files deleted, 
  1722.  and the total space freed by the deletions. 
  1723.  
  1724.  To improve performance, DEL calculates the space freed by comparing space 
  1725.  available on the drive before and after the deletions, rather than checking 
  1726.  the size of each file.  Therefore, if other programs are allocating or 
  1727.  deallocating disk space while a DEL command is in process, the figure for 
  1728.  space freed may reflect the results of those other operations as well as those 
  1729.  of the DEL command itself. 
  1730.  
  1731.  If DEL finds that free space on your drive has decreased or remained the same 
  1732.  after the deletions, the space freed is not displayed.  This may happen if 
  1733.  other programs are modifying the disk while DEL is running, or if you have 
  1734.  enabled DELDIR to save deleted files for recovery (see your OS/2 documentation 
  1735.  for information on DELDIR). 
  1736.  
  1737.  EXAMPLES 
  1738.  
  1739.  Erase all the files in the current directory with a .BAK or .PRN extension: 
  1740.  
  1741.       del *.bak *.prn
  1742.  
  1743.  Delete the entire subdirectory tree starting with C:\UTIL, including hidden 
  1744.  and read-only files, without further prompting (use with caution!): 
  1745.  
  1746.       del /sxyz c:\util
  1747.  
  1748.  
  1749. ΓòÉΓòÉΓòÉ 3.16. DELAY - Pause for specified time ΓòÉΓòÉΓòÉ
  1750.  
  1751. SYNTAX     (Internal 4OS2) 
  1752.  
  1753. DELAY [seconds]
  1754.  
  1755. PURPOSE 
  1756.  
  1757. Pause for a specified period of time. 
  1758.  
  1759. COMMENTS 
  1760.  
  1761. DELAY is useful in batch file loops while waiting for a condition to occur. The 
  1762. default value is one second. 
  1763.  
  1764. If you need a shorter delay, use BEEP with a frequency < 37 Hz. 
  1765.  
  1766. You can cancel a DELAY loop by pressing ^C. 
  1767.  
  1768. See also BEEP. 
  1769.  
  1770. EXAMPLE 
  1771.  
  1772. Wait for 10 seconds: 
  1773.  
  1774.     delay 10
  1775.  
  1776.  
  1777. ΓòÉΓòÉΓòÉ 3.17. DESCRIBE - Describe files ΓòÉΓòÉΓòÉ
  1778.  
  1779. SYNTAX     (Internal 4OS2) 
  1780.  
  1781. DESCRIBE [d:][path]filename... ["description"]
  1782.  
  1783. PURPOSE 
  1784.  
  1785. Create, modify, or delete file and subdirectory descriptions. 
  1786.  
  1787. COMMENTS 
  1788.  
  1789. DESCRIBE adds descriptions to filenames and subdirectories.  The descriptions 
  1790. will be displayed when using DIR with the default single column option, or when 
  1791. using SELECT.  If you're using 4OS2 on an HPFS volume, descriptions will only 
  1792. be displayed if you use the DIR or SELECT /Z (FAT format) option.  The default 
  1793. maximum description length is 40 characters; if you have a screen capable of 
  1794. displaying more than 80 columns, you can increase the maximum description 
  1795. length with the 4OS2.INI DescriptionMax option. 
  1796.  
  1797. File descriptions allow you to identify your files in much more meaningful ways 
  1798. than an eight character filename. 
  1799.  
  1800. You can enter a description on the command line by entering the filename 
  1801. followed by the description enclosed in quotes.  Using wildcards and/or 
  1802. multiple filenames with a description on the command line will give all 
  1803. matching files the same description. 
  1804.  
  1805. Descriptions are stored in each directory in a hidden file called DESCRIPT.ION. 
  1806. Use the ATTRIB command to "unhide" this file if you need to copy or delete it. 
  1807.  
  1808. The description file is modified appropriately whenever you perform an internal 
  1809. command (such as COPY, DEL, MOVE, or RENAME), but not if you use an external 
  1810. command (such as REPLACE or XCOPY). 
  1811.  
  1812. See also DIR and SELECT. 
  1813.  
  1814. EXAMPLES 
  1815.  
  1816. Create a description for the file MEMO.TXT interactively: 
  1817.  
  1818.     describe memo.txt
  1819.  
  1820. Create the same description in a single command: 
  1821.  
  1822.     describe memo.txt "Memo to Bob about party"
  1823.  
  1824.  
  1825. ΓòÉΓòÉΓòÉ 3.18. DETACH - Start detached process ΓòÉΓòÉΓòÉ
  1826.  
  1827. SYNTAX     (Internal 4OS2) 
  1828.  
  1829. DETACH [d:][command ...]
  1830.  
  1831. PURPOSE 
  1832.  
  1833. Start OS/2 commands in detached mode. 
  1834.  
  1835. COMMENTS 
  1836.  
  1837. A command started with DETACH cannot use the keyboard, mouse, or video display. 
  1838. You can redirect standard I/O to other devices if necessary. 
  1839.  
  1840. 4OS2 always detaches another copy of 4OS2.EXE to execute the command.  This 
  1841. allows you to deatch any type of command including an alias, internal command, 
  1842. external command, or batch file. 
  1843.  
  1844. The entire command line after DETACH is passed to the detached process.  If you 
  1845. place multiple commands on the line after DETACH, all those commands will be 
  1846. run by the detached copy of 4OS2.  The current copy of 4OS2 will continue with 
  1847. the first command on the next line. 
  1848.  
  1849. EXAMPLES 
  1850.  
  1851. Detach a CHKDSK command and redirect its output to the file CHECK.DAT: 
  1852.  
  1853.     detach chkdsk >& check.dat
  1854.  
  1855. Detach CHKDSK commands for drives C and D, redirecting the output of each to 
  1856. the file CHECK.DAT in the root directory of the corresponding drive: 
  1857.  
  1858.     detach chkdsk c: >& c:\check.dat & chkdsk d: >& d:\check.dat
  1859.  
  1860.  
  1861. ΓòÉΓòÉΓòÉ 3.19. DIR - Display directory ΓòÉΓòÉΓòÉ
  1862.  
  1863. SYNTAX     (Internal 4OS2) 
  1864.  
  1865. DIR [/1 /2 /4 /A[:-rhsda] /B /C /D /F /J /K /L /M /N /O:-deginrsu
  1866.     /P /S /T[:acw] /U /V /W /Z] [[d:][path]filename...]
  1867.  
  1868. PURPOSE 
  1869.  
  1870. Display information about files and subdirectories. 
  1871.  
  1872. COMMENTS 
  1873.  
  1874. DIR displays information about the files and subdirectories in the specified 
  1875. directory.  Depending upon the options specified, DIR can show the filename, 
  1876. file attributes, size, date and time of the most recent change to the file, and 
  1877. the file description. 
  1878.  
  1879. For files on HPFS drives, the /T:acw switch can be used to specify whether to 
  1880. display the date and time of last access, file creation, or last write. 
  1881.  
  1882. The DIR options are: 
  1883.  
  1884.     /1          Single column display - display the filename, size, date, time, 
  1885.                 and description.  This is the default. 
  1886.  
  1887.     /2          Two column display - display the filename, size, date, and 
  1888.                 time. 
  1889.  
  1890.     /4          Four column display - display the filename and size, in 
  1891.                 K(ilobytes) or M(egabytes). 
  1892.  
  1893.     /A          Display only those files that have the specified attribute set. 
  1894.                 A /A with no attributes will display all files, including 
  1895.                 hidden and system files.  Preceding the attribute character 
  1896.                 with a '-' will display those files that do not have that 
  1897.                 attribute set.  Attributes can also be combined.  The 
  1898.                 attributes are: 
  1899.                   R  Read only 
  1900.                   H  Hidden 
  1901.                   S  System 
  1902.                   D  Directory 
  1903.                   A  Archive 
  1904.  
  1905.     /B          Suppress header line and summaries, and display file or 
  1906.                 subdirectory names only, in a single column (useful when 
  1907.                 redirecting output to a file or another program). 
  1908.  
  1909.     /C          Display FAT filenames in upper case (like CMD.EXE).  See also 
  1910.                 SETDOS /U. 
  1911.  
  1912.     /D          Disable directory colorization. 
  1913.  
  1914.     /F          Display fully expanded filenames (including drive & path) in 
  1915.                 one column. 
  1916.  
  1917.     /J          Justify filenames (same format as CMD.EXE). 
  1918.  
  1919.     /K          Suppress the header display. 
  1920.  
  1921.     /L          Display FAT filenames in lower case.  This option will not 
  1922.                 convert extended ASCII characters to lower case. 
  1923.  
  1924.     /M          Suppress the footer display. 
  1925.  
  1926.     /N          Display a FAT volume in HPFS format. 
  1927.  
  1928.     /O          Sort order; any combination of the following options: 
  1929.                   -  Reverse the sort order for the next option 
  1930.                   a  Sort by ASCII value rather than numeric value 
  1931.                   d  Sort by date and time (oldest first; also see /T:acw 
  1932.                 below) 
  1933.                   e  Sort by extension 
  1934.                   g  Group subdirectories together 
  1935.                   i  Sort by the file description 
  1936.                   n  Sort by the filename (this is the default) 
  1937.                   r  Reverse the sort order for all options 
  1938.                   s  Sort by size 
  1939.                   u  Unsorted 
  1940.  
  1941.     /P          Pause after each screen page and wait for a key to be pressed 
  1942.                 (useful for displaying long directory listings). 
  1943.  
  1944.     /S          Display contents of the current directory and all of its 
  1945.                 subdirectories.  DIR will only display headers and summaries 
  1946.                 for those directories with matching filenames. 
  1947.  
  1948.     /T          Display the filenames and attributes only (see ATTRIB), in the 
  1949.                 format RHSA, where: 
  1950.                   R  Read only 
  1951.                   H  Hidden 
  1952.                   S  System 
  1953.                   A  Archive 
  1954.  
  1955.                 When displaying attributes, DIR cannot display file 
  1956.                 descriptions. 
  1957.  
  1958.     /T:acw       Select the date and time used for file date / time displays 
  1959.                 and date / time sorts on HPFS drives.  This option is ignored 
  1960.                 for FAT drives.  Use any one of the following options: 
  1961.                   a  Use date and time of last access 
  1962.                   c  Use date and time of creation 
  1963.                   w  Use date and time of last write 
  1964.  
  1965.                 If /T is used without a date / time type (:acw) after it, 4OS2 
  1966.                 will display the file attributes (see /T above). 
  1967.  
  1968.     /U          Display summary only (number of files & bytes used; both actual 
  1969.                 file size and the disk space used). 
  1970.  
  1971.     /V          Display filenames sorted vertically rather than horizontally 
  1972.                 (with the /2, /4, or /W option). 
  1973.  
  1974.     /W          Wide display - display the filenames only, horizontally across 
  1975.                 the screen (5 columns on an 80-character display). 
  1976.  
  1977.     /Z          Display an HPFS volume in FAT format.  Filenames longer than 12 
  1978.                 characters will be truncated. 
  1979.  
  1980.  DIR allows wildcard characters in the filename.  If you don't specify a 
  1981.  filename, DIR defaults to *.* (display all files and subdirectories in the 
  1982.  current directory). 
  1983.  
  1984.  If you append filenames with a ; (an "include list"), DIR will display the 
  1985.  matching filenames in a single directory listing.  Only the first file in an 
  1986.  include list can have a path. 
  1987.  
  1988.  You can display the subdirectories and files in color by setting the COLORDIR 
  1989.  variable.  The format for COLORDIR is: 
  1990.  
  1991.       ext [...]:[bright][blink] fg [ON bg]; ...
  1992.  
  1993.  where "ext" is the file extension, or one of the following file attributes: 
  1994.  
  1995.       DIRS - directory
  1996.       RDONLY - read-only file
  1997.       HIDDEN - hidden file
  1998.       SYSTEM - system file
  1999.       ARCHIVE - file modified since last backup
  2000.  
  2001.  For example, to display the .COM and .EXE files in red, the .C and .ASM files 
  2002.  in bright cyan, and the read-only files in blinking green: 
  2003.  
  2004.       set colordir=com exe:red; c asm:bright cyan; rdonly:blink green
  2005.  
  2006.  If you don't select a background color, DIR will use the current screen 
  2007.  background color. 
  2008.  
  2009.  If a country code was defined in the CONFIG.SYS file or by the CHCP command, 
  2010.  DIR will display the date in the format for that country.  The default date 
  2011.  format is U.S. (mm-dd-yy). 
  2012.  
  2013.  Options on the command line apply only to the filenames that follow the 
  2014.  option, except that options at the end of the line apply to the preceding 
  2015.  filename only.  This allows you to specify several options for a group of 
  2016.  files, and retains compatibility with CMD.EXE when a single filename is 
  2017.  specified. 
  2018.  
  2019.  See also DESCRIBE and SELECT. 
  2020.  
  2021.  EXAMPLES 
  2022.  
  2023.  Display the .WKS files, and then the .WK1 files in the current directory: 
  2024.  
  2025.       dir *.wks *.wk1
  2026.  
  2027.  Display the .WKS and .WK1 files together (an "include list"): 
  2028.  
  2029.       dir *.wks;*.wk1
  2030.  
  2031.  Display the files on drive C, including hidden and system files, pausing after 
  2032.  each page: 
  2033.  
  2034.       dir /a/sp c:\*.*
  2035.  
  2036.  
  2037. ΓòÉΓòÉΓòÉ 3.20. DIRS - Display directory stack ΓòÉΓòÉΓòÉ
  2038.  
  2039. SYNTAX     (Internal 4OS2) 
  2040.  
  2041. DIRS
  2042.  
  2043. PURPOSE 
  2044.  
  2045. Display the current directory stack. 
  2046.  
  2047. COMMENTS 
  2048.  
  2049. DIRS displays the directory stack used by PUSHD and POPD, oldest entries first. 
  2050. The stack holds 255 characters (about 10 to 20 entries). 
  2051.  
  2052. See also PUSHD and POPD. 
  2053.  
  2054. EXAMPLE 
  2055.  
  2056. Change directories and then display the directory stack: 
  2057.  
  2058.     pushd c:\database
  2059.     pushd d:\wordp\memos
  2060.     dirs
  2061.  
  2062.  
  2063. ΓòÉΓòÉΓòÉ 3.21. DPATH - Display / set data search path ΓòÉΓòÉΓòÉ
  2064.  
  2065. SYNTAX     (Internal 4OS2) 
  2066.  
  2067. DPATH [[d:]path][[;[d:]path]...]]
  2068. DPATH ;
  2069.  
  2070. PURPOSE 
  2071.  
  2072. Tells applications where to search for their files. 
  2073.  
  2074. COMMENTS 
  2075.  
  2076. If you enter DPATH with no parameters, 4OS2 displays the current search path. 
  2077. If you enter DPATH and a semicolon (;), 4OS2 clears the search path. 
  2078.  
  2079. You can edit an existing DPATH with the ESET command. 
  2080.  
  2081. EXAMPLES 
  2082.  
  2083. The following DPATH command directs applications to search for their data files 
  2084. in the following order: the current directory, the root directory on drive C, 
  2085. the OS2 subdirectory on drive C, and the UTIL subdirectory on drive C: 
  2086.  
  2087.     dpath c:\;c:\os2;c:\util
  2088.  
  2089. Display the current DPATH: 
  2090.  
  2091.     dpath
  2092.  
  2093.  
  2094. ΓòÉΓòÉΓòÉ 3.22. DRAWBOX - Draw a box ΓòÉΓòÉΓòÉ
  2095.  
  2096. SYNTAX     (Internal 4OS2) 
  2097.  
  2098. DRAWBOX ulrow ulcol lrrow lrcol style [bright][blink] fg ON bg
  2099.     [FILL bgfill] [SHADOW]
  2100.  
  2101. PURPOSE 
  2102.  
  2103. Draw a box on the screen. 
  2104.  
  2105. COMMENTS 
  2106.  
  2107. DRAWBOX is useful for creating attractive screen displays in batch files. 
  2108. DRAWBOX detects other lines and boxes on the display, and creates the 
  2109. appropriate connector characters when possible (not all types of lines can be 
  2110. connected with the available characters). 
  2111.  
  2112. The row and column numbering is zero-based, so on a standard 25 line by 80 
  2113. column display, valid rows are 0 - 24 and valid columns are 0 - 79. 
  2114.  
  2115. The DRAWBOX parameters are: 
  2116.  
  2117.     ulrow         Row for upper left corner 
  2118.  
  2119.     ulcol         Column for upper left corner 
  2120.  
  2121.     lrrow         Row for lower right corner 
  2122.  
  2123.     lrcol         Column for lower right corner 
  2124.  
  2125.     style         Box drawing style: 
  2126.                     0  no line drawing characters (box is drawn with blanks) 
  2127.                     1  single line 
  2128.                     2  double line 
  2129.                     3  single line on top and bottom, double on sides 
  2130.                     4  double line on top and bottom, single on sides 
  2131.  
  2132.     fg            Foreground character color 
  2133.  
  2134.     bg            Background character color 
  2135.  
  2136.     bgfill        Background fill color (for the inside of the box) 
  2137.  
  2138.     SHADOW        Include a transparent drop shadow 
  2139.  
  2140.  Only the first three characters of the color name and attributes ("bright" and 
  2141.  "blink") are required. 
  2142.  
  2143.  The available colors are: 
  2144.  
  2145.       Black      Blue      Green      Red
  2146.       Magenta    Cyan      Yellow     White
  2147.  
  2148.  See also DRAWHLINE and DRAWVLINE. 
  2149.  
  2150.  EXAMPLE 
  2151.  
  2152.  Draw a single line box around the entire screen with bright white lines on a 
  2153.  blue background: 
  2154.  
  2155.       drawbox 0 0 24 79 1 bright white on blue fill blue
  2156.  
  2157.  
  2158. ΓòÉΓòÉΓòÉ 3.23. DRAWHLINE - Draw horizontal line ΓòÉΓòÉΓòÉ
  2159.  
  2160. SYNTAX     (Internal 4OS2) 
  2161.  
  2162. DRAWHLINE row column length style [bright] [blink] fg ON bg
  2163.  
  2164. PURPOSE 
  2165.  
  2166. Draw a horizontal line on the screen. 
  2167.  
  2168. COMMENTS 
  2169.  
  2170. DRAWHLINE is useful for creating attractive screen displays in batch files. 
  2171. DRAWHLINE detects other lines and boxes on the display, and creates the 
  2172. appropriate connector characters when possible (not all types of lines can be 
  2173. connected with the available characters). 
  2174.  
  2175. The row and column numbering is zero-based, so on a standard 25 line by 80 
  2176. column display, valid rows are 0 - 24 and valid columns are 0 - 79. 
  2177.  
  2178. The DRAWHLINE parameters are: 
  2179.  
  2180.     row         Start row 
  2181.  
  2182.     column      Start column 
  2183.  
  2184.     length      Length of line 
  2185.  
  2186.     style       Line drawing style: 
  2187.                   1  Single line 
  2188.                   2  Double line 
  2189.  
  2190.     fg          Foreground character color 
  2191.  
  2192.     bg          Background character color 
  2193.  
  2194.  Only the first three characters of the color name and attributes ("bright" and 
  2195.  "blink") are required. 
  2196.  
  2197.  The available colors are: 
  2198.  
  2199.       Black      Blue      Green      Red
  2200.       Magenta    Cyan      Yellow     White
  2201.  
  2202.  See also DRAWBOX, DRAWVLINE and SCRPUT. 
  2203.  
  2204.  EXAMPLE 
  2205.  
  2206.  Draw a double line along the top row of the display with green characters on a 
  2207.  blue background: 
  2208.  
  2209.       drawhline 0 0 79 2 green on blue
  2210.  
  2211.  
  2212. ΓòÉΓòÉΓòÉ 3.24. DRAWVLINE - Draw vertical line ΓòÉΓòÉΓòÉ
  2213.  
  2214. SYNTAX     (Internal 4OS2) 
  2215.  
  2216. DRAWVLINE row column length style [bright] [blink] fg ON bg
  2217.  
  2218. PURPOSE 
  2219.  
  2220. Draw a vertical line on the screen. 
  2221.  
  2222. COMMENTS 
  2223.  
  2224. DRAWVLINE is useful for creating attractive screen displays in batch files. 
  2225. DRAWVLINE detects other lines and boxes on the display, and creates the 
  2226. appropriate connector characters when possible (not all types of lines can be 
  2227. connected with the available characters). 
  2228.  
  2229. The row and column numbering is zero-based, so on a standard 25 line by 80 
  2230. column display, valid rows are 0 - 24 and valid columns are 0 - 79. 
  2231.  
  2232. The DRAWVLINE parameters are: 
  2233.  
  2234.     row         Start row 
  2235.  
  2236.     column      Start column 
  2237.  
  2238.     length      Length of line 
  2239.  
  2240.     style       Line drawing style: 
  2241.                   1  Single line 
  2242.                   2  Double line 
  2243.  
  2244.     fg          Foreground character color 
  2245.  
  2246.     bg          Background character color 
  2247.  
  2248.  Only the first three characters of the color name and attributes ("bright" and 
  2249.  "blink") are required. 
  2250.  
  2251.  The available colors are: 
  2252.  
  2253.       Black      Blue      Green      Red
  2254.       Magenta    Cyan      Yellow     White
  2255.  
  2256.  See also DRAWBOX, DRAWHLINE, and VSCRPUT. 
  2257.  
  2258.  EXAMPLE 
  2259.  
  2260.  Draw a double line along the left margin of the display with bright red 
  2261.  characters on a black background: 
  2262.  
  2263.       drawvline 0 0 24 2 bright red on black
  2264.  
  2265.  
  2266. ΓòÉΓòÉΓòÉ 3.25. ECHO - Display a message ΓòÉΓòÉΓòÉ
  2267.  
  2268. SYNTAX     (Internal 4OS2) 
  2269.  
  2270. ECHO [on | off | message]
  2271.  
  2272. PURPOSE 
  2273.  
  2274. Display the echo status, enable or disable batch file or command line echoing, 
  2275. or display a message. 
  2276.  
  2277. COMMENTS 
  2278.  
  2279. ECHO defaults to ON in batch files.  To prevent a line from being echoed, 
  2280. preface it with the @ symbol.  You can default to ECHO OFF by setting the 
  2281. SETDOS /V option to 0.  (Setting SETDOS /V to 2 will echo all lines, regardless 
  2282. of the echo state or @ symbols.)  The current ECHO state is inherited by called 
  2283. batch files. 
  2284.  
  2285. ECHO defaults to OFF during keyboard input.  If you set ECHO ON from the 
  2286. command line, the fully parsed and expanded commands (including aliases and 
  2287. variables) will be displayed before they are executed.  The keyboard ECHO state 
  2288. is independent of the batch file ECHO state; changing ECHO in a batch file has 
  2289. no effect on the display at the command prompt, and vice versa. 
  2290.  
  2291. If no arguments are entered, ECHO displays the current echo state. 
  2292.  
  2293. ECHO commands in a batch file will send messages to the screen while the batch 
  2294. file executes, even if ECHO is set OFF.  You cannot use the command separator 
  2295. character or the redirection symbols (|><) in an ECHO message, unless you 
  2296. enclose them in quotes or precede them with the escape character.  If you want 
  2297. to echo a blank line, enter: 
  2298.  
  2299.     echo.
  2300.  
  2301. See also ECHOS, SETDOS, SCREEN, SCRPUT, TEXT and VSCRPUT. 
  2302.  
  2303. EXAMPLES 
  2304.  
  2305. Enable command line echoing: 
  2306.  
  2307.     echo on
  2308.  
  2309. Display a message in a batch file: 
  2310.  
  2311.     echo Processing your print files...
  2312.  
  2313. Turn off batch file echoing, without displaying the ECHO command itself: 
  2314.  
  2315.     @echo off
  2316.  
  2317.  
  2318. ΓòÉΓòÉΓòÉ 3.26. ECHOS - Display a message with no CR/LF ΓòÉΓòÉΓòÉ
  2319.  
  2320. SYNTAX     (Internal 4OS2) 
  2321.  
  2322. ECHOS message
  2323.  
  2324. PURPOSE 
  2325.  
  2326. Display a message, without printing a trailing CR/LF. 
  2327.  
  2328. COMMENTS 
  2329.  
  2330. ECHOS is useful for outputting text when you don't want ECHO to add a carriage 
  2331. return / linefeed pair (for example, when redirecting control sequences to a 
  2332. printer).  You cannot use the command separator character or the redirection 
  2333. symbols (|><) in an ECHOS message, unless you enclose them in quotes or precede 
  2334. them with the escape character. 
  2335.  
  2336. See also ECHO. 
  2337.  
  2338. EXAMPLE 
  2339.  
  2340. Send a control sequence (an Esc+H) to the printer. 
  2341.  
  2342.     echos ^eH > lpt1:
  2343.  
  2344.  
  2345. ΓòÉΓòÉΓòÉ 3.27. ENDLOCAL - Restore saved environment ΓòÉΓòÉΓòÉ
  2346.  
  2347. SYNTAX     (Internal 4OS2) 
  2348.  
  2349. ENDLOCAL
  2350.  
  2351. PURPOSE 
  2352.  
  2353. Restore the saved disk drive, directory, aliases, and environment. 
  2354.  
  2355. COMMENTS 
  2356.  
  2357. ENDLOCAL restores the disk drive, directory, aliases, and environment variables 
  2358. saved by the previous SETLOCAL command.  SETLOCAL and ENDLOCAL can only be used 
  2359. in batch files, not in aliases. 
  2360.  
  2361. See also SETLOCAL. 
  2362.  
  2363. EXAMPLE 
  2364.  
  2365. This batch file fragment saves the aliases, environment, drive, and current 
  2366. working directory, changes the drive and directory, modifies some environment 
  2367. variables, runs the program TEST1, and then restores the original values: 
  2368.  
  2369.     setlocal
  2370.     cdd d:\test
  2371.     set path=c:\;c:\dos;c:\util
  2372.     set lib=d:\lib
  2373.     test1
  2374.     endlocal
  2375.  
  2376.  
  2377. ΓòÉΓòÉΓòÉ 3.28. ESET - Edit variable or alias ΓòÉΓòÉΓòÉ
  2378.  
  2379. SYNTAX     (Internal 4OS2) 
  2380.  
  2381. ESET [/A] varname...
  2382.  
  2383. PURPOSE 
  2384.  
  2385. Edit environment variables and/or aliases. 
  2386.  
  2387. COMMENTS 
  2388.  
  2389. ESET allows you to edit your environment variables and aliases using the line 
  2390. editing commands.  The cursor will be positioned at the first character of the 
  2391. variable or alias. 
  2392.  
  2393. The ESET options are: 
  2394.  
  2395.     /A      Assume the argument is an alias.  This allows you to edit an alias 
  2396.             with the same name as an environment variable. 
  2397.  
  2398.  ESET will search for environment variables first, and then aliases. 
  2399.  
  2400.  Environment variable and alias names are limited to 80 characters, and their 
  2401.  arguments to 255 characters. 
  2402.  
  2403.  See also Editing the Command Line, ALIAS, UNALIAS, SET, and UNSET. 
  2404.  
  2405.  EXAMPLES 
  2406.  
  2407.  Edit the executable file search path: 
  2408.  
  2409.       eset path
  2410.  
  2411.  Create and then edit an alias: 
  2412.  
  2413.       alias d dir /djp
  2414.       eset d
  2415.  
  2416.  
  2417. ΓòÉΓòÉΓòÉ 3.29. EXCEPT - Exclude files from command ΓòÉΓòÉΓòÉ
  2418.  
  2419. SYNTAX     (Internal 4OS2) 
  2420.  
  2421. EXCEPT ([d:][path]filename...) command
  2422.  
  2423. PURPOSE 
  2424.  
  2425. Perform a command, except on the file(s) specified. 
  2426.  
  2427. COMMENTS 
  2428.  
  2429. EXCEPT provides a means of executing a command on a group of files and/or 
  2430. subdirectories, except those enclosed within the parentheses. 
  2431.  
  2432. The command can be an internal command or alias, an external command, or a 
  2433. batch file. 
  2434.  
  2435. You may use wildcard characters in a filename. 
  2436.  
  2437. When using filename completion (TAB or F9) to get the filenames inside the 
  2438. parentheses, type a space after the open parenthesis before entering a partial 
  2439. filename or pressing TAB. Otherwise the command line editor will treat the open 
  2440. parenthesis as the first character of the filename to be completed. 
  2441.  
  2442. EXCEPT prevents operations on the specified file(s) by setting the hidden 
  2443. attribute, performing the command, and then clearing the hidden attribute. If 
  2444. EXCEPT is aborted in an unusual way, you may need to use the ATTRIB command to 
  2445. "unhide" (-H) the file(s). 
  2446.  
  2447. EXCEPT will not work with programs or commands that ignore the hidden 
  2448. attribute. 
  2449.  
  2450. See also ATTRIB. 
  2451.  
  2452. EXAMPLE 
  2453.  
  2454. Erase all but the files beginning with MEMO and those ending in .WKS: 
  2455.  
  2456.     except (memo*.* *.wks) del *.*
  2457.  
  2458.  
  2459. ΓòÉΓòÉΓòÉ 3.30. EXIT - Exit secondary processor ΓòÉΓòÉΓòÉ
  2460.  
  2461. SYNTAX     (Internal 4OS2) 
  2462.  
  2463. EXIT [value]
  2464.  
  2465. PURPOSE 
  2466.  
  2467. Exit the current command processor. 
  2468.  
  2469. COMMENTS 
  2470.  
  2471. Some application programs will start a secondary copy of the command processor 
  2472. to allow you execute commands.  To return to the application again, type EXIT. 
  2473.  
  2474. If you EXIT from a primary command processor, you will be returned to PM. 
  2475.  
  2476. If you specify a value, EXIT will return that value to the parent process. 
  2477.  
  2478. EXAMPLE 
  2479.  
  2480. Return to the parent process: 
  2481.  
  2482.     exit
  2483.  
  2484.  
  2485. ΓòÉΓòÉΓòÉ 3.31. FOR - Repeat a command ΓòÉΓòÉΓòÉ
  2486.  
  2487. SYNTAX     (Internal 4OS2) 
  2488.  
  2489. FOR [/A[:-RHSDA]] %%var IN (set) [DO] command
  2490.  
  2491. PURPOSE 
  2492.  
  2493. Repeat a command for several variables. 
  2494.  
  2495. COMMENTS 
  2496.  
  2497. FOR sets var sequentially to each member of (set), and then evaluates and 
  2498. executes command for every argument in (set). If an argument in (set) contains 
  2499. wildcard characters, var will be set sequentially to each matching filename on 
  2500. the disk.  If a filename in (set) begins with an @, var will be set 
  2501. sequentially to each line in the file.  You can nest multiple FOR statements. 
  2502.  
  2503. The only option for FOR is: 
  2504.  
  2505.     /A      Retrieve only those files with the specified attribute.  A /A with 
  2506.             no attributes will retrieve all files, including hidden and system 
  2507.             files, and subdirectories.  Preceding the attribute character with 
  2508.             a '-' will retrieve those files that DON'T have that attribute set. 
  2509.             Attributes can also be combined.  The attributes are: 
  2510.               R  Read only 
  2511.               H  Hidden 
  2512.               S  System 
  2513.               D  Directory 
  2514.               A  Archive 
  2515.  
  2516.  The command can be an internal command or alias, an external command, or a 
  2517.  batch file. 
  2518.  
  2519.  In CMD.EXE you must use a single % for the variable name from the command 
  2520.  line, and %% when in a batch file.  4OS2 will accept either % or %% in either 
  2521.  case. 
  2522.  
  2523.  CMD.EXE requires the variable name to be a single character; 4OS2 supports 
  2524.  variable names up to 80 characters. 
  2525.  
  2526.  CMD.EXE requires the word DO on the command line; it is optional in 4OS2. 
  2527.  
  2528.  EXAMPLES 
  2529.  
  2530.  The following example compiles the C programs in the current directory that 
  2531.  have a "2" or a "3" somewhere in their name: 
  2532.  
  2533.       for %a in (*2*.c *3*.c) do cl %a ;
  2534.  
  2535.  The following example uses variable functions to delete the .BAK files for 
  2536.  which a corresponding .TXT file exists in the current directory: 
  2537.  
  2538.       for %a in (*.txt) if exist %@name[%a].bak del %@name[%a].bak
  2539.  
  2540.  
  2541. ΓòÉΓòÉΓòÉ 3.32. FREE - Display disk utilization ΓòÉΓòÉΓòÉ
  2542.  
  2543. SYNTAX     (Internal 4OS2) 
  2544.  
  2545. FREE [d:] ...
  2546.  
  2547. PURPOSE 
  2548.  
  2549. Display the total disk space, total bytes used, and total bytes free on the 
  2550. specified (or default) drive(s). 
  2551.  
  2552. COMMENTS 
  2553.  
  2554. FREE provides the same disk information as the external command CHKDSK, but 
  2555. without the wait. 
  2556.  
  2557. EXAMPLE 
  2558.  
  2559. Display the status of drives A, B, and C: 
  2560.  
  2561.     free a: b: c:
  2562.  
  2563.  
  2564. ΓòÉΓòÉΓòÉ 3.33. GLOBAL - Execute command in all subdirectories ΓòÉΓòÉΓòÉ
  2565.  
  2566. SYNTAX     (Internal 4OS2) 
  2567.  
  2568. GLOBAL [/H /I /P /Q] command
  2569.  
  2570. PURPOSE 
  2571.  
  2572. Execute a command in the current directory and its subdirectories. 
  2573.  
  2574. COMMENTS 
  2575.  
  2576. GLOBAL performs the specified command first in the current directory, and then 
  2577. in every subdirectory under the current directory. 
  2578.  
  2579. The command can be an internal command or alias, an external command, or a 
  2580. batch file. 
  2581.  
  2582. The GLOBAL options are: 
  2583.  
  2584.     /H      Process hidden subdirectories. 
  2585.  
  2586.     /I      Ignore exit codes.  If this option is not specified, GLOBAL will 
  2587.             terminate if the command returns a non-zero exit code. 
  2588.  
  2589.     /P      Prompt for a Y/N whether to execute the command in each directory. 
  2590.  
  2591.     /Q      Do not display the directory names as each directory is accessed. 
  2592.  
  2593.  EXAMPLE 
  2594.  
  2595.  Copy the files in every directory on drive A to the directory C:\TEMP: 
  2596.  
  2597.       cd a:\ & global copy a:*.* c:\temp
  2598.  
  2599.  
  2600. ΓòÉΓòÉΓòÉ 3.34. GOSUB - Call batch subroutine ΓòÉΓòÉΓòÉ
  2601.  
  2602. SYNTAX     (Internal 4OS2) 
  2603.  
  2604. GOSUB label
  2605.  
  2606. PURPOSE 
  2607.  
  2608. Call a subroutine in a batch file. 
  2609.  
  2610. COMMENTS 
  2611.  
  2612. GOSUB calls the specified label as a subroutine.  The subroutine must end with 
  2613. a RETURN statement.  After the RETURN, the batch file continues with the 
  2614. command following the GOSUB command. 
  2615.  
  2616. GOSUB searches for the label starting at the first line of the batch file. If 
  2617. the label doesn't exist, the batch file is terminated with the error message 
  2618. "Label not found." 
  2619.  
  2620. The label must begin with a colon (:), and appear by itself on the line. GOSUB 
  2621. ignores case differences when matching labels. 
  2622.  
  2623. See also GOTO and RETURN. 
  2624.  
  2625. EXAMPLE 
  2626.  
  2627. The following batch file fragment calls a subroutine that displays the 
  2628. directory and returns: 
  2629.  
  2630.     echo Calling a subroutine
  2631.     gosub subr1
  2632.     echo Returned from the subroutine
  2633.     quit
  2634.     :subr1
  2635.     dir /hw
  2636.     return
  2637.  
  2638.  
  2639. ΓòÉΓòÉΓòÉ 3.35. GOTO - Jump to batch label ΓòÉΓòÉΓòÉ
  2640.  
  2641. SYNTAX     (Internal 4OS2) 
  2642.  
  2643. GOTO [/I] label
  2644.  
  2645. PURPOSE 
  2646.  
  2647. Continue batch file processing at the line following the label. 
  2648.  
  2649. COMMENTS 
  2650.  
  2651. GOTO changes the current position in the batch file to the line immediately 
  2652. following the label. 
  2653.  
  2654. The search for the label starts at the first line of the batch file. If the 
  2655. label doesn't exist, the batch file is terminated with the error message "Label 
  2656. not found." 
  2657.  
  2658. The label must begin with a colon (:), and appear by itself on the line. GOTO 
  2659. ignores case differences when matching labels. 
  2660.  
  2661. A GOTO will cancel all IFF nesting, unless you specify the /I option. 
  2662.  
  2663. See also GOSUB. 
  2664.  
  2665. EXAMPLE 
  2666.  
  2667. The following batch file fragment checks for the existence of the file 
  2668. CONFIG.SYS.  If CONFIG.SYS exists, GOTO jumps to C_EXISTS and copies all the 
  2669. files from the current directory to the root directory on A.  If CONFIG.SYS 
  2670. doesn't exist, the batch file prints an error message and exits. 
  2671.  
  2672.     if exist config.sys goto C_EXISTS
  2673.     echo CONFIG.SYS doesn't exist - exiting
  2674.     quit
  2675.     :c_exists
  2676.     copy *.* a:\
  2677.  
  2678.  
  2679. ΓòÉΓòÉΓòÉ 3.36. HELP - Display 4OS2 online help ΓòÉΓòÉΓòÉ
  2680.  
  2681. SYNTAX     (Internal 4OS2) 
  2682.  
  2683. HELP [command]
  2684.  
  2685. PURPOSE 
  2686.  
  2687. Display the 4OS2 help file. 
  2688.  
  2689. COMMENTS 
  2690.  
  2691. HELP uses the PM VIEW.EXE program to display help for 4OS2 (4OS2.INF) and OS/2 
  2692. in general (CMDREF.INF).  You can change the default .INF files with the 
  2693. HelpBook directive in 4OS2.INI. 
  2694.  
  2695. EXAMPLES 
  2696.  
  2697. Display the HELP table of contents: 
  2698.  
  2699.     help
  2700.  
  2701. Display help for the DIR command: 
  2702.  
  2703.     help dir
  2704.  
  2705.  
  2706. ΓòÉΓòÉΓòÉ 3.37. HISTORY - Display / set command history ΓòÉΓòÉΓòÉ
  2707.  
  2708. SYNTAX     (Internal 4OS2) 
  2709.  
  2710. HISTORY [/A command] [/F /P] [/R [d:][path]filename]
  2711.  
  2712. PURPOSE 
  2713.  
  2714. Display, read, or clear the history list. 
  2715.  
  2716. COMMENTS 
  2717.  
  2718. If no parameters are entered, HISTORY displays the current history list. 
  2719.  
  2720. The HISTORY options are: 
  2721.  
  2722.     /A      Add the specified command to the history list. 
  2723.  
  2724.     /F      Clear the command history list. 
  2725.  
  2726.     /P      Prompt for a key after displaying each page. 
  2727.  
  2728.     /R      Read the command history from the specified file. You can save the 
  2729.             history list by redirecting the output of HISTORY to a file. 
  2730.  
  2731.  The number of commands saved in the history list depends on the length of each 
  2732.  command line.  The history list size can be specified at startup from 256 to 
  2733.  8192 characters.  The default size is 1024 characters. 
  2734.  
  2735.  You can disable saving commands to the history list, or specify a minimum 
  2736.  command line length to save, with the HistMin directive in 4OS2.INI. 
  2737.  
  2738.  EXAMPLES 
  2739.  
  2740.  Display the history list: 
  2741.  
  2742.       history
  2743.  
  2744.  Clear the history entries: 
  2745.  
  2746.       history /f
  2747.  
  2748.  Save the history list to the file HISTFILE, and then read it in again: 
  2749.  
  2750.       history > histfile
  2751.       history /r histfile
  2752.  
  2753.  
  2754. ΓòÉΓòÉΓòÉ 3.38. IF - Conditional command execution ΓòÉΓòÉΓòÉ
  2755.  
  2756. SYNTAX     (Internal 4OS2) 
  2757.  
  2758. IF [NOT] condition [.AND. | .OR. | .XOR. [NOT] ...] command
  2759.  
  2760. PURPOSE 
  2761.  
  2762. Allow conditional execution of commands. 
  2763.  
  2764. COMMENTS 
  2765.  
  2766. IF first tests the given condition.  If the condition is true, IF executes the 
  2767. specified command, otherwise the command will be ignored.  If you use the NOT 
  2768. option, the command is executed only when the condition is false.  IF 
  2769. statements can be nested. 
  2770.  
  2771. The command can be an internal command or alias, an external command, or a 
  2772. batch file. 
  2773.  
  2774. For the string tests, case differences are ignored.  When comparing strings, 
  2775. you should enclose them in double quotes (see examples).  The use of double 
  2776. quotes reduces problems when the strings being compared contain characters that 
  2777. may have another meaning to the parser.  If the strings begin with a digit, IF 
  2778. will do a numeric comparison. Otherwise, IF does an ASCII comparison. 
  2779.  
  2780. The .AND., .OR., and .XOR. tests allow you to combine tests in an IF statement. 
  2781. The expressions are scanned from left to right. 
  2782.  
  2783. The condition can be any of the following: 
  2784.  
  2785.     string1 == string2   or   string1 EQ string2
  2786.         If string1 is equal to string2, the condition is true. 
  2787.  
  2788.     string1 != string2   or   string1 NE string2
  2789.         If string1 is not equal to string2, the condition is true. 
  2790.  
  2791.     string1 LT string2
  2792.         If string1 is < string2, the condition is true. 
  2793.  
  2794.     string1 LE string2
  2795.         If string1 is <= string2, the condition is true. 
  2796.  
  2797.     string1 GE string2
  2798.         If string1 is >= string2, the condition is true. 
  2799.  
  2800.     string1 GT string2
  2801.         If string1 is > string2, the condition is true. 
  2802.  
  2803.  In the tests below, the term "condition" refers to one of the relational 
  2804.  operators described for the string tests above (==, EQ, NE, LT, etc.). 
  2805.  
  2806.     ERRORLEVEL [condition] number
  2807.         Test the exit code of the preceding external program.  If no relational 
  2808.         operator (EQ, GT, etc.) is specified, the default is GE. NOTE:  Not all 
  2809.         programs return an explicit exit code.  In those cases, the behavior of 
  2810.         ERRORLEVEL is undefined. 
  2811.  
  2812.     EXIST [d:][path]filename
  2813.         If the file exists, the condition is true.  You can use wildcard 
  2814.         characters in the filename, in which case the condition is true if any 
  2815.         file matching the wildcards exists. 
  2816.  
  2817.     ISALIAS aliasname
  2818.         If the specified name is an alias, the condition is true. 
  2819.  
  2820.     ISDIR [d:]path
  2821.         If the subdirectory exists, the condition is true. 
  2822.  
  2823.     ISINTERNAL command
  2824.         If the specified command is an internal command, the condition is true. 
  2825.  
  2826.     ISLABEL labelname
  2827.         If the specified label exists in the current batch file, the condition 
  2828.         is true. 
  2829.  
  2830.  See also IFF. 
  2831.  
  2832.  EXAMPLES 
  2833.  
  2834.  Test for the presence of A:\JAN.DOC and copy it to the root directory on drive 
  2835.  C if it exists: 
  2836.  
  2837.       if exist a:\jan.doc copy a:\jan.doc c:\
  2838.  
  2839.  This batch file fragment tests for a string value: 
  2840.  
  2841.       if "%cmd" == "wp" goto wordproc
  2842.       if "%cmd" NE "graphics" goto badentry
  2843.  
  2844.  Test for more than 500K of free disk space on drive A: 
  2845.  
  2846.       if %@diskfree[a:] gt 500 echo More than 500K free
  2847.  
  2848.  Run the program MONOPROG if the monitor type is monochrome: 
  2849.  
  2850.       if %_monitor == mono monoprog
  2851.  
  2852.  
  2853. ΓòÉΓòÉΓòÉ 3.39. IFF - Conditional command execution ΓòÉΓòÉΓòÉ
  2854.  
  2855. SYNTAX     (Internal 4OS2) 
  2856.  
  2857. IFF [NOT] condition [.AND. | .OR. | .XOR. [NOT] ...]
  2858.     THEN & ... & ELSE[[IFF] ... THEN] & ... & ENDIFF
  2859.  
  2860. PURPOSE 
  2861.  
  2862. Allow IF/THEN/ELSE conditional execution of commands. 
  2863.  
  2864. COMMENTS 
  2865.  
  2866. IFF first tests the given condition.  If the condition is true, IFF executes 
  2867. the specified command(s) until the next ELSE, ELSEIFF, or ENDIFF; otherwise the 
  2868. command(s) will be ignored and parsing will continue at the next ELSE, ELSEIFF, 
  2869. or ENDIFF.  If you use the NOT option, commands are executed only when the 
  2870. condition is false.  IFF statements can be nested up to 15 levels deep. 
  2871.  
  2872. The .AND., .OR., and .XOR. tests allow you to combine tests in an IFF 
  2873. statement.  The expressions are scanned from left to right; each new .AND., 
  2874. .OR., or .XOR. tests the combination of all preceding tests. 
  2875.  
  2876. The command can be an internal command or alias, an external command, or a 
  2877. batch file. 
  2878.  
  2879. If you do a GOTO inside an IFF, GOTO assumes you are jumping outside the IFF 
  2880. statement.  You cannot GOTO another part of the same IFF, or inside another IFF 
  2881. statement. 
  2882.  
  2883. See the IF command for a list of the tests available. 
  2884.  
  2885. EXAMPLES 
  2886.  
  2887. The following batch file fragment tests the monitor type (monochrome or color), 
  2888. and sets the appropriate colors and prompt: 
  2889.  
  2890.     iff %_monitor == color then
  2891.       color bright white on blue & cls
  2892.       prompt=$e[s$e[1;1f$e[41;1;37m$e[K  Path: $p$e[u$e[44;37m$n$g
  2893.     else
  2894.       prompt=$e[s$e[1;1f$e[0;7m$e[K  Path: $p$e[u$e[0m$n$g
  2895.     endiff
  2896.  
  2897. The following alias checks to see if the argument is a subdirectory.  If so, 
  2898. the alias deletes the subdirectory's files and removes it (enter this on one 
  2899. line): 
  2900.  
  2901.     alias zap `iff isdir %1 then & del /s/x/z %1 & else &
  2902.        echo Not a directory! & endiff`
  2903.  
  2904.  
  2905. ΓòÉΓòÉΓòÉ 3.40. INKEY - Enter environment variable ΓòÉΓòÉΓòÉ
  2906.  
  2907. SYNTAX     (Internal 4OS2) 
  2908.  
  2909. INKEY [/K"..." /Wn] [text] %%varname
  2910.  
  2911. PURPOSE 
  2912.  
  2913. Get a single keystroke environment variable from standard input. 
  2914.  
  2915. COMMENTS 
  2916.  
  2917. You can optionally display prompt text before the variable name. 
  2918.  
  2919. The INKEY options are: 
  2920.  
  2921.     /K      The allowable keystrokes, enclosed in double quotes.  If you want 
  2922.             to read a control or function key, you must enclose it in square 
  2923.             brackets (for example, /K"ab[F1][F10]"). The valid key names are 
  2924.             the same as those listed in the section on Key Mapping Directives 
  2925.             in KEYCODES. 
  2926.  
  2927.     /W      Timeout period, where "n" is the number of seconds to wait for a 
  2928.             response.  If no keystroke is entered by the end of the timeout 
  2929.             period, INKEY returns with the variable unchanged.  You can specify 
  2930.             /W0 to check if a keystroke is waiting, and return immediately. 
  2931.  
  2932.  ASCII values from 1 to 255 are stored as a character.  Extended characters 
  2933.  (for example, function keys & cursor keys) are stored as a string in decimal 
  2934.  format, with a leading @ (for example, the F1 key is stored as @59).  The 
  2935.  ENTER character is a special case; it is stored as its scan code (@28).  See 
  2936.  KEYCODES for the common extended keystrokes. 
  2937.  
  2938.  INKEY and INPUT are normally used as batch file commands, allowing you great 
  2939.  flexibility in entering or changing batch variables. 
  2940.  
  2941.  If you press ^C or ^BREAK while INKEY is waiting for a key, execution of an 
  2942.  alias will be terminated, and execution of a batch file will be suspended 
  2943.  while you are prompted whether to cancel the batch job. 
  2944.  
  2945.  See also INPUT. 
  2946.  
  2947.  EXAMPLES 
  2948.  
  2949.  Prompt for a number and store it in the variable NUM: 
  2950.  
  2951.       inkey /K"123456789" Enter a number from 1 to 9:  %%num
  2952.  
  2953.  The following batch file fragment waits up to 10 seconds for a character, then 
  2954.  tests to see if a "Y" was entered: 
  2955.  
  2956.       set net=N
  2957.       inkey /w10 Do you want to load the network (Y/N)? %%net
  2958.       if "%net"=="Y" goto load_net
  2959.  
  2960.  
  2961. ΓòÉΓòÉΓòÉ 3.41. INPUT - Enter environment variable ΓòÉΓòÉΓòÉ
  2962.  
  2963. SYNTAX     (Internal 4OS2) 
  2964.  
  2965. INPUT [/Wn] [text] %%varname
  2966.  
  2967. PURPOSE 
  2968.  
  2969. Enter an environment variable from the standard input. 
  2970.  
  2971. COMMENTS 
  2972.  
  2973. You can optionally display prompt text before the variable name. 
  2974.  
  2975. The only INPUT option is: 
  2976.  
  2977.     /W      Specify a timeout period, where "n" is the number of seconds to 
  2978.             wait for a response.  If no keystroke is entered by the end of the 
  2979.             timeout period, INPUT returns with the variable unchanged.  If you 
  2980.             enter a key before the timeout period, INPUT will wait indefinitely 
  2981.             for the remainder of the line.  You can specify /W0 to check if a 
  2982.             key is already in the buffer, and return immediately. 
  2983.  
  2984.  All characters entered up to, but not including, the carriage return are 
  2985.  stored in the variable. 
  2986.  
  2987.  INPUT and INKEY are normally used as batch file commands, allowing you great 
  2988.  flexibility in entering or changing batch variables. 
  2989.  
  2990.  See also INKEY. 
  2991.  
  2992.  EXAMPLE 
  2993.  
  2994.  The following batch file fragment prompts for a string and stores it in the 
  2995.  variable FNAME: 
  2996.  
  2997.       input Enter the file name:  %%fname
  2998.  
  2999.  
  3000. ΓòÉΓòÉΓòÉ 3.42. KEYS - Display command history ΓòÉΓòÉΓòÉ
  3001.  
  3002. SYNTAX     (Internal 4OS2) 
  3003.  
  3004. KEYS [ON | OFF | LIST]
  3005.  
  3006. PURPOSE 
  3007.  
  3008. Display the history list, or enable / disable the command line editing keys. 
  3009.  
  3010. COMMENTS 
  3011.  
  3012. 4OS2 includes this command for compatibility with CMD.EXE; for 4OS2 you should 
  3013. normally use the HISTORY command instead. 
  3014.  
  3015. KEYS OFF will disable the command history and force 4OS2 to read input a line 
  3016. at a time (normally input is processed one character at a time). Applications 
  3017. which intercept line input intended for the command processor may not work 
  3018. properly unless you use KEYS OFF to switch to line input mode before starting 
  3019. the application (such applications are very rare). KEYS ON will reenable the 
  3020. command history and return input to the usual character by character method. 
  3021.  
  3022.  
  3023. ΓòÉΓòÉΓòÉ 3.43. LIST - Display files ΓòÉΓòÉΓòÉ
  3024.  
  3025. SYNTAX     (Internal 4OS2) 
  3026.  
  3027. LIST [/H /S /W] [d:][path]filename...
  3028.  
  3029. PURPOSE 
  3030.  
  3031. Display a file with forward and backward paging and scrolling. 
  3032.  
  3033. COMMENTS 
  3034.  
  3035. LIST provides a much faster and more flexible way to view a file than TYPE, 
  3036. without the overhead of using a text editor. 
  3037.  
  3038. The LIST options are: 
  3039.  
  3040.     /H        Strip the high bit from each character before displaying.  This 
  3041.               is useful when displaying files created by some word processors 
  3042.               that turn on the high bit for formatting purposes. 
  3043.  
  3044.     /S        Read from the standard input rather than a file.  This allows you 
  3045.               to redirect command output and view it with LIST. 
  3046.  
  3047.     /W        Wrap the text at the right margin.  This option is useful when 
  3048.               displaying non-text files. 
  3049.  
  3050.  LIST uses the cursor pad to scroll through the file.  The LIST commands are 
  3051.  (the caret ^ means press the Ctrl key together with the specified key): 
  3052.  
  3053.     HOME      Display the first page of the file 
  3054.     END       Display the last page of the file 
  3055.     PgUp      Scroll back one page 
  3056.     PgDn      Scroll forwards one page 
  3057.     Esc       Exit the current file 
  3058.     ^C        Quit LIST 
  3059.              Scroll up one line 
  3060.              Scroll down one line 
  3061.              Scroll left 8 columns 
  3062.              Scroll right 8 columns 
  3063.     ^        Scroll left 40 columns 
  3064.     ^        Scroll right 40 columns 
  3065.     F1        Call the on-line help 
  3066.     F         Prompt and search for a string (case is ignored) 
  3067.     H         Toggle the "strip high bit" (/H) option 
  3068.     N         Find next matching string (case is ignored).  LIST saves the 
  3069.               search string, so you can LIST multiple files and search for the 
  3070.               same string by pressing N in each file. 
  3071.     P         Print the file on LPT1 
  3072.     W         Toggle the "line wrap" (/W) option 
  3073.  
  3074.  LIST is normally only useful for displaying ASCII text files; executable files 
  3075.  (.COM and .EXE) and many data files will be unreadable due to the presence of 
  3076.  non-alphanumeric characters. 
  3077.  
  3078.  See also TYPE. 
  3079.  
  3080.  EXAMPLES 
  3081.  
  3082.  Display the file MEMO.DOC: 
  3083.  
  3084.       list memo.doc
  3085.  
  3086.  Display the output from a DIR command: 
  3087.  
  3088.       dir | list /s
  3089.  
  3090.  
  3091. ΓòÉΓòÉΓòÉ 3.44. LOADBTM - Change batch file mode ΓòÉΓòÉΓòÉ
  3092.  
  3093. SYNTAX     (Internal 4OS2) 
  3094.  
  3095. LOADBTM [on | off]
  3096.  
  3097. PURPOSE 
  3098.  
  3099. Switch a batch file to or from .BTM mode. 
  3100.  
  3101. COMMENTS 
  3102.  
  3103. LOADBTM switches a batch file (.CMD or .BTM) to and from .BTM mode. If no 
  3104. argument is given, it displays the current LOADBTM status. 
  3105.  
  3106. .BTM mode runs from two to five times faster than normal batch mode, but should 
  3107. not be used for self-modifying batch files. 
  3108.  
  3109. LOADBTM can only be used within a .CMD or .BTM file. 
  3110.  
  3111. See the 4OS2 / 4DOS manual for more information on .BTM files. 
  3112.  
  3113. EXAMPLE 
  3114.  
  3115. The following .CMD batch file fragment tests if 4OS2 is the current command 
  3116. processor; if so, it switches to BTM mode: 
  3117.  
  3118.     Rem The initial default state is LOADBTM OFF
  3119.     if "%@eval[2+2]" == "4" loadbtm on
  3120.  
  3121.  
  3122. ΓòÉΓòÉΓòÉ 3.45. LOG - Log commands to file ΓòÉΓòÉΓòÉ
  3123.  
  3124. SYNTAX     (Internal 4OS2) 
  3125.  
  3126. LOG [/W [d:]pathname] [ON | OFF | "text"]
  3127.  
  3128. PURPOSE 
  3129.  
  3130. Save a log of commands to a disk file. 
  3131.  
  3132. COMMENTS 
  3133.  
  3134. The default 4OS2 LOG filename is 4OS2LOG in the root directory of the boot 
  3135. drive.  The LOG status and log filename will be passed to secondary shells. 
  3136.  
  3137. Entering LOG with no parameters displays the log status (ON or OFF). Entering 
  3138. LOG with text writes the text to the log file, even if LOG is set OFF.  This 
  3139. allows you to enter headers in the log file. 
  3140.  
  3141. You can specify a different filename with the /W(rite) option.  /W 
  3142. automatically enables command logging. 
  3143.  
  3144. The commands are stored in the log file as they are executed, after performing 
  3145. any alias or variable expansion. 
  3146.  
  3147. The LOG file format looks like: 
  3148.  
  3149.     [mm/dd/yy  hh:mm:ss] command.
  3150.  
  3151. EXAMPLES 
  3152.  
  3153. Display the LOG status: 
  3154.  
  3155.     log
  3156.  
  3157. Enable command logging: 
  3158.  
  3159.     log on
  3160.  
  3161. Enable command logging to the file C:\LOG\LOGFILE and insert a header: 
  3162.  
  3163.     log /w c:\log\logfile
  3164.     log "Started work on the database system"
  3165.  
  3166.  
  3167. ΓòÉΓòÉΓòÉ 3.46. MD or MKDIR - Create subdirectory ΓòÉΓòÉΓòÉ
  3168.  
  3169. SYNTAX     (Internal 4OS2) 
  3170.  
  3171. MD [d:]pathname...
  3172. MKDIR [d:]pathname...
  3173.  
  3174. PURPOSE 
  3175.  
  3176. Create subdirectories. 
  3177.  
  3178. COMMENTS 
  3179.  
  3180. To start at the root directory, start the pathname with a backslash (\). To 
  3181. start at the parent directory, start the pathname with two periods (..). All 
  3182. other pathnames start at the current directory. 
  3183.  
  3184. See also RD. 
  3185.  
  3186. EXAMPLE 
  3187.  
  3188. Create a subdirectory called MYDIR in the root directory: 
  3189.  
  3190.     md \mydir
  3191.  
  3192.  
  3193. ΓòÉΓòÉΓòÉ 3.47. MEMORY - Display system memory ΓòÉΓòÉΓòÉ
  3194.  
  3195. SYNTAX     (Internal 4OS2) 
  3196.  
  3197. MEMORY
  3198.  
  3199. PURPOSE 
  3200.  
  3201. Display the system RAM status. 
  3202.  
  3203. COMMENTS 
  3204.  
  3205. MEMORY displays the size of the largest free block of RAM, the size of the OS/2 
  3206. swap file, the total and free environment space, the total and free alias list 
  3207. space, and the total command history space.  Swap file size is displayed only 
  3208. if the swap file is located in the \OS2\SYSTEM directory on the boot drive 
  3209. (this is the default location). 
  3210.  
  3211. OS/2 provides virtual memory and swaps applications to disk as needed. This 
  3212. makes the size of the largest available free block of RAM as reported by MEMORY 
  3213. only a general reflection of available memory resources, and not a precise 
  3214. statement of the amount of RAM available for applications. 
  3215.  
  3216. In 4OS2/32 only, MEMORY also displays the size of physical and resident RAM. 
  3217.  
  3218. EXAMPLE 
  3219.  
  3220. Display your RAM totals: 
  3221.  
  3222.     memory
  3223.  
  3224.  
  3225. ΓòÉΓòÉΓòÉ 3.48. MOVE - Move files ΓòÉΓòÉΓòÉ
  3226.  
  3227. SYNTAX     (Internal 4OS2) 
  3228.  
  3229. MOVE [d:][path]filename... [d:][path][filename]
  3230.     [/C /D /H /N /P /Q /R /S /U]
  3231.  
  3232. PURPOSE 
  3233.  
  3234. Move files to other directories and drives. 
  3235.  
  3236. COMMENTS 
  3237.  
  3238. The MOVE command moves the specified file(s) to the last filename specified, 
  3239. which is designated as the target.  If the target already exists, it is deleted 
  3240. when the file is moved.  You cannot move a file to itself. 
  3241.  
  3242. If there is more than one source file specification, the target must be a 
  3243. directory, and the files are moved to the directory with their original 
  3244. filenames.  If the target is not a directory, MOVE will display an error 
  3245. message and exit. 
  3246.  
  3247. Use caution when using MOVE commands with commands like SELECT.  If multiple 
  3248. files are selected and the target is not a subdirectory, each file will be 
  3249. moved in turn to the target, overwriting the previous file. The net result is 
  3250. that all files but the last will be deleted.  If SELECT is invoked using square 
  3251. brackets instead of parentheses, the MOVE will be done in a single command and 
  3252. MOVE will detect the error. 
  3253.  
  3254. The MOVE options are: 
  3255.  
  3256.     /C      Move only files that exist in the target directory, and where the 
  3257.             source file is newer than the target. 
  3258.  
  3259.     /D      The target must be a directory.  If it doesn't exist, you will be 
  3260.             prompted whether to create it. 
  3261.  
  3262.     /H      Move all files, including hidden & system. 
  3263.  
  3264.     /N      Do everything except actually move the file(s) (for testing what 
  3265.             the result of a MOVE would be). 
  3266.  
  3267.     /P      Prompt for a Y or N response to confirm each move. 
  3268.  
  3269.     /Q      Don't display filenames as they are moved. 
  3270.  
  3271.     /R      Prompt for a Y or N response before overwriting an existing file. 
  3272.  
  3273.     /S      Move an entire subdirectory tree to another location.  The target 
  3274.             directories will be created if they don't exist (except for the 
  3275.             first target, which must already exist).  MOVE will remove empty 
  3276.             subdirectories after the move. 
  3277.  
  3278.     /U      Move only those files that either don't exist in the target 
  3279.             directory, or where the source file is newer than the target. 
  3280.  
  3281.  MOVE first attempts to rename the file(s).  If that fails (the target is on a 
  3282.  different drive, or the target already exists), MOVE will copy the file(s) and 
  3283.  then delete the originals.  If MOVE cannot delete the original (for example, a 
  3284.  read-only file), it will display an error message, but the target file is 
  3285.  still created. 
  3286.  
  3287.  See also COPY and REN. 
  3288.  
  3289.  EXAMPLES 
  3290.  
  3291.  Move some files to a different directory: 
  3292.  
  3293.       move *.wks *.txt c:\finance\myfiles
  3294.  
  3295.  Move all the files in the current directory to A:\, prompting before 
  3296.  overwriting any existing files: 
  3297.  
  3298.       move /r *.* a:\
  3299.  
  3300.  
  3301. ΓòÉΓòÉΓòÉ 3.49. PATH - Set executable file search path ΓòÉΓòÉΓòÉ
  3302.  
  3303. SYNTAX     (Internal 4OS2) 
  3304.  
  3305. PATH [[d:]path][[;[d:]path]...]]
  3306. PATH ;
  3307.  
  3308. PURPOSE 
  3309.  
  3310. Tells 4OS2 where to search for executable and batch files not in the current 
  3311. directory. 
  3312.  
  3313. COMMENTS 
  3314.  
  3315. When searching for an external command (.COM, .EXE, .BTM, and .CMD, in that 
  3316. order), 4OS2 searches the current directory first, then the directories you 
  3317. specify in the PATH, in the order you list them. The directory names are 
  3318. separated by semicolons (;). 
  3319.  
  3320. In OS/2 2.0, 4OS2 will also search for MS-DOS .BAT files (following .CMD in the 
  3321. search order), for compatibility with CMD.EXE. 
  3322.  
  3323. If you enter PATH with no parameters, PATH displays the current search path. 
  3324. If you enter PATH and a semicolon (;), PATH clears the search path and will 
  3325. search only the current directory (this is the default at system startup). 
  3326.  
  3327. If you specify an invalid directory, 4OS2 will skip that directory and continue 
  3328. searching with the next directory in the path. 
  3329.  
  3330. If you have a directory '.' in the PATH, 4OS2 will not search the current 
  3331. directory first, but will wait to do so until it reaches that point in the 
  3332. PATH. 
  3333.  
  3334. Some applications also use the PATH variable to search for their files. 
  3335.  
  3336. You can edit an existing path with the ESET command. 
  3337.  
  3338. EXAMPLES 
  3339.  
  3340. The following PATH command sets the search path to the following order: the 
  3341. current directory, the root directory on drive C, the OS2 subdirectory on drive 
  3342. C, and the UTIL subdirectory on drive C: 
  3343.  
  3344.     path c:\;c:\os2;c:\util
  3345.  
  3346. Display the current search path: 
  3347.  
  3348.     path
  3349.  
  3350.  
  3351. ΓòÉΓòÉΓòÉ 3.50. PAUSE - Wait for keystroke ΓòÉΓòÉΓòÉ
  3352.  
  3353. SYNTAX     (Internal 4OS2) 
  3354.  
  3355. PAUSE [message]
  3356.  
  3357. PURPOSE 
  3358.  
  3359. Suspend alias or batch file execution. 
  3360.  
  3361. COMMENTS 
  3362.  
  3363. A PAUSE command will suspend execution, giving you the opportunity to perform 
  3364. activities such as changing disks, turning on the printer, etc. 
  3365.  
  3366. PAUSE waits for any key (except ^C or ^BREAK) to be pressed and then continues 
  3367. executing.  If a prompt message is specified, PAUSE will display the message 
  3368. and wait for a keystroke.  Otherwise, PAUSE will prompt: 
  3369.  
  3370.     Press a key when ready...
  3371.  
  3372. If you press a ^C or ^BREAK while PAUSE is waiting for a key, execution of an 
  3373. alias will be terminated, and execution of a batch file will be suspended while 
  3374. you are prompted whether to cancel the batch file. 
  3375.  
  3376. EXAMPLE 
  3377.  
  3378. The following batch file fragment prompts the user before erasing files: 
  3379.  
  3380.     pause ^C aborts, any other key erases the .LST files:
  3381.     erase *.lst
  3382.  
  3383.  
  3384. ΓòÉΓòÉΓòÉ 3.51. POPD - Restore saved directory ΓòÉΓòÉΓòÉ
  3385.  
  3386. SYNTAX     (Internal 4OS2) 
  3387.  
  3388. POPD [*]
  3389.  
  3390. PURPOSE 
  3391.  
  3392. Change to the disk drive and directory at the top of the directory stack. 
  3393.  
  3394. COMMENTS 
  3395.  
  3396. POPD restores the disk and directory saved using PUSHD (most recent first). 
  3397.  
  3398. The * option clears the directory stack, without changing the current drive and 
  3399. directory. 
  3400.  
  3401. Use the DIRS command to display the directory stack. 
  3402.  
  3403. See also DIRS and PUSHD. 
  3404.  
  3405. EXAMPLES 
  3406.  
  3407. Save and change your disk drive with PUSHD, and then restore it: 
  3408.  
  3409.     pushd d:\database\test
  3410.     popd
  3411.  
  3412. Clear the directory stack: 
  3413.  
  3414.     popd *
  3415.  
  3416.  
  3417. ΓòÉΓòÉΓòÉ 3.52. PROMPT - Change command prompt ΓòÉΓòÉΓòÉ
  3418.  
  3419. SYNTAX     (Internal 4OS2) 
  3420.  
  3421. PROMPT [text]
  3422.  
  3423. PURPOSE 
  3424.  
  3425. Change the command line prompt. 
  3426.  
  3427. COMMENTS 
  3428.  
  3429. If you enter PROMPT with no parameters, PROMPT sets the prompt on drives A and 
  3430. B to $n$g (display current disk only), and on all other drives to $p$g (display 
  3431. current disk and directory). 
  3432.  
  3433. The prompt text can contain special strings of the form $?, where ? is one of 
  3434. the following: 
  3435.  
  3436.     b      The | character 
  3437.     c      The open parenthesis ( 
  3438.     D      Current date, in the format:  Fri  Dec 25, 1992 
  3439.     d      Current date, in the format:  Fri  12-25-92 
  3440.     e      The ASCII ESC character (decimal 27) 
  3441.     f      The close parenthesis ) 
  3442.     g      The > character 
  3443.     h      BACKSPACE over the previous character 
  3444.     i      The default OS/2 line 0 prompt 
  3445.     l      The < character 
  3446.     n      Default drive letter 
  3447.     P      Current disk and directory (upper case) 
  3448.     p      Current disk and directory (lower case) 
  3449.     q      The = character 
  3450.     r      The numeric exit code returned by the last external command 
  3451.     s      The space character 
  3452.     t      Current time, in the format hh:mm:ss 
  3453.     v      OS/2 version number, in the format:  2.0 
  3454.     Xd:    Current disk and directory (upper case) where d: is the drive 
  3455.            specification 
  3456.     xd:    Current disk and directory (lower case) where d: is the drive 
  3457.            specification 
  3458.     z      Display the current shell nesting level (you must be running 4OS2 as 
  3459.            the primary shell in swapping mode).  The primary command processor 
  3460.            is 0. 
  3461.     $      The $ character 
  3462.     _      CR/LF (go to beginning of new line) 
  3463.  
  3464.  You can embed any environment variable, internal variable, or variable 
  3465.  function in your PROMPT string to view system status or resources.  When 
  3466.  defining the PROMPT to include variables of this type, use two % signs before 
  3467.  the variable name, or enclose the prompt string in back-quotes [`] (if you 
  3468.  don't, the prompt display will show the value the variable had when the prompt 
  3469.  was defined, not the value at the moment the prompt is displayed).  For 
  3470.  example, to show free RAM to the left of the standard $p$g prompt: 
  3471.  
  3472.       prompt [%%@dosmem[K]K] $p$g
  3473.         or
  3474.       prompt `[%@dosmem[K]K] $p$g`
  3475.  
  3476.  See 4OS2 Internal Variables and 4OS2 Variable Functions for lists of the 
  3477.  available variables and functions. 
  3478.  
  3479.  See also ANSI. 
  3480.  
  3481.  EXAMPLE 
  3482.  
  3483.  Set the prompt to the current date and time: 
  3484.  
  3485.       prompt $d $t $g
  3486.  
  3487.  
  3488. ΓòÉΓòÉΓòÉ 3.53. PUSHD - Save & change directory ΓòÉΓòÉΓòÉ
  3489.  
  3490. SYNTAX     (Internal 4OS2) 
  3491.  
  3492. PUSHD [[d:]pathname]
  3493.  
  3494. PURPOSE 
  3495.  
  3496. Save the current disk and directory. 
  3497.  
  3498. COMMENTS 
  3499.  
  3500. PUSHD saves the current directory on the directory stack, and if a pathname is 
  3501. specified on the command line, changes the disk drive and directory. The 
  3502. directory stack can hold up to 255 characters (about 10 to 20 entries). If you 
  3503. exceed the directory stack size, the oldest directory is removed before adding 
  3504. the current directory. 
  3505.  
  3506. The saved directory is restored on a "last in, first out" basis by the POPD 
  3507. command.  The directory stack can be displayed with the DIRS command. 
  3508.  
  3509. See also DIRS and POPD. 
  3510.  
  3511. EXAMPLE 
  3512.  
  3513. Save the current directory and change to C:\WORDP\MEMOS: 
  3514.  
  3515.     pushd c:\wordp\memos
  3516.  
  3517.  
  3518. ΓòÉΓòÉΓòÉ 3.54. QUIT - Quit batch file ΓòÉΓòÉΓòÉ
  3519.  
  3520. SYNTAX     (Internal 4OS2) 
  3521.  
  3522. QUIT [value]
  3523.  
  3524. PURPOSE 
  3525.  
  3526. Terminate the current batch file. 
  3527.  
  3528. COMMENTS 
  3529.  
  3530. You can QUIT at any point in a batch file, not just the end.  If you QUIT a 
  3531. batch file called from another batch file, you will be returned to the previous 
  3532. file at the command following the original call.  To end all batch file 
  3533. processing, use CANCEL.  If you specify a value, QUIT will set the ERRORLEVEL 
  3534. to that value.  The value also affects the internal variable %_?, and the 
  3535. conditional command separators && and ||. 
  3536.  
  3537. You can also use QUIT in an alias.  If you QUIT an alias while inside a batch 
  3538. file, QUIT will end both the alias and the batch file. 
  3539.  
  3540. See also CANCEL. 
  3541.  
  3542. EXAMPLE 
  3543.  
  3544. Check to see if the user entered "quit" and exit if true: 
  3545.  
  3546.     input Enter your choice:  %%option
  3547.     if "%option" == "quit" quit
  3548.  
  3549.  
  3550. ΓòÉΓòÉΓòÉ 3.55. RD or RMDIR - Remove subdirectory ΓòÉΓòÉΓòÉ
  3551.  
  3552. SYNTAX     (Internal 4OS2) 
  3553.  
  3554. RD [d:]path...
  3555. RMDIR [d:]path...
  3556.  
  3557. PURPOSE 
  3558.  
  3559. Remove one or more directories. 
  3560.  
  3561. COMMENTS 
  3562.  
  3563. Before removing a subdirectory, you must delete all the files and 
  3564. subdirectories (and their files) in that directory (including any hidden or 
  3565. read-only files). 
  3566.  
  3567. You can use wildcard characters in the directory names. 
  3568.  
  3569. You cannot remove the root directory (\), the current directory (.), or the 
  3570. parent directory (..). 
  3571.  
  3572. See also MD. 
  3573.  
  3574. EXAMPLE 
  3575.  
  3576. Remove the subdirectory MEMOS from the directory WP on the current drive: 
  3577.  
  3578.     rmdir \wp\memos
  3579.  
  3580.  
  3581. ΓòÉΓòÉΓòÉ 3.56. REBOOT - Reboot system ΓòÉΓòÉΓòÉ
  3582.  
  3583. SYNTAX     (Internal 4OS2) 
  3584.  
  3585. REBOOT [/V]
  3586.  
  3587. PURPOSE 
  3588.  
  3589. Reboot the system. 
  3590.  
  3591. COMMENTS 
  3592.  
  3593. The only option for REBOOT is: 
  3594.  
  3595.     /V      Prompt for confirmation (Y or N) before rebooting. 
  3596.  
  3597.  REBOOT shuts down the file systems before rebooting the system, to allow the 
  3598.  disk caches to finish writing any cached data. 
  3599.  
  3600.  EXAMPLE 
  3601.  
  3602.  The following command prompts you to verify the reboot: 
  3603.  
  3604.       reboot /v
  3605.  
  3606.  
  3607. ΓòÉΓòÉΓòÉ 3.57. REM - Batch file comment ΓòÉΓòÉΓòÉ
  3608.  
  3609. SYNTAX     (Internal 4OS2) 
  3610.  
  3611. REM [comment]
  3612.  
  3613. PURPOSE 
  3614.  
  3615. Put a comment in a batch file. 
  3616.  
  3617. COMMENTS 
  3618.  
  3619. If ECHO is ON, or the SETDOS /V option is set, REM will echo the comment. 
  3620. Otherwise, REM will ignore it. If you don't want to echo the line, preface REM 
  3621. with the @ character. (Setting SETDOS /V to 2 will echo all lines, regardless 
  3622. of the echo state or @ symbols.)  The current ECHO state is inherited by called 
  3623. batch files. 
  3624.  
  3625. Enter your comment following the REM, separated by a space or tab. Comments can 
  3626. be up to 295 characters.  Everything following a REM will be ignored, including 
  3627. quote characters, the redirection symbols (|><) and the command separator 
  3628. character.  An alternate way to put a comment in a batch file is to begin the 
  3629. line with a colon (:). The line will be interpreted as a label and ignored. 
  3630. (Make sure you don't have any actual labels beginning with the same word!) 
  3631.  
  3632. Batch file comments are useful for documenting the purpose for a batch file and 
  3633. the procedures used. 
  3634.  
  3635. EXAMPLE 
  3636.  
  3637. Enter comments in a batch file: 
  3638.  
  3639.     rem This batch file provides a menu-based system
  3640.     rem   for accessing the rem word processing utilities.
  3641.     rem Clear the screen and get a selection
  3642.     cls
  3643.  
  3644.  
  3645. ΓòÉΓòÉΓòÉ 3.58. REN or RENAME - Rename files ΓòÉΓòÉΓòÉ
  3646.  
  3647. SYNTAX     (Internal 4OS2) 
  3648.  
  3649. REN [/N /P /Q] [d:][path]filename... [d:][path]filename
  3650. RENAME [/N /P /Q] [d:][path]filename... [d:][path]filename
  3651.  
  3652. PURPOSE 
  3653.  
  3654. Rename files or subdirectories. 
  3655.  
  3656. COMMENTS 
  3657.  
  3658. The last filename is the new name; preceding names are the files or directories 
  3659. to be renamed.  You can use wildcard characters in the filenames.  The new 
  3660. filename must not already exist.  You cannot rename a subdirectory to a new 
  3661. path! 
  3662.  
  3663. The REN options are: 
  3664.  
  3665.     /N      Do everything except actually rename the file(s) (for testing what 
  3666.             the result of a REN would be). 
  3667.  
  3668.     /P      Confirm each rename (Y or N). 
  3669.  
  3670.     /Q      Don't display filenames as they are renamed. 
  3671.  
  3672.  REN in CMD.EXE only allows a path to be specified with the first file name; 
  3673.  the path for the target is always the same as the source.  4OS2 allows you to 
  3674.  optionally select the target path, renaming the source file to a new directory 
  3675.  on the same disk drive.  If you don't specify a path for the target, REN will 
  3676.  assume a "CMD.EXE compatible RENAME" and will rename the source file to the 
  3677.  new name without moving it to another directory. 
  3678.  
  3679.  If you want to rename to a different drive, use MOVE. 
  3680.  
  3681.  See also MOVE. 
  3682.  
  3683.  EXAMPLES 
  3684.  
  3685.  Rename the file MEMO.TXT to OFFICE.TXT: 
  3686.  
  3687.       ren memo.txt office.txt
  3688.  
  3689.  Rename the directory \WORDPROC to \WP: 
  3690.  
  3691.       ren \wordproc \wp
  3692.  
  3693.  
  3694. ΓòÉΓòÉΓòÉ 3.59. RETURN - Return from batch subroutine ΓòÉΓòÉΓòÉ
  3695.  
  3696. SYNTAX     (Internal 4OS2) 
  3697.  
  3698. RETURN
  3699.  
  3700. PURPOSE 
  3701.  
  3702. Return from a GOSUB (subroutine) call in a batch file. 
  3703.  
  3704. COMMENTS 
  3705.  
  3706. The RETURN command returns from a GOSUB call to the command following the 
  3707. original GOSUB. 
  3708.  
  3709. See also GOSUB. 
  3710.  
  3711. EXAMPLE 
  3712.  
  3713. The following batch file fragment calls a subroutine that displays the current 
  3714. directory: 
  3715.  
  3716.     echo Calling a subroutine
  3717.     gosub subr1
  3718.     echo Returned from the subroutine
  3719.     quit
  3720.     :subr1
  3721.     dir /hw
  3722.     return
  3723.  
  3724.  
  3725. ΓòÉΓòÉΓòÉ 3.60. SCREEN - Position cursor ΓòÉΓòÉΓòÉ
  3726.  
  3727. SYNTAX     (Internal 4OS2) 
  3728.  
  3729. SCREEN row column [message]
  3730.  
  3731. PURPOSE 
  3732.  
  3733. Position the cursor on the screen, and optionally display a message. 
  3734.  
  3735. COMMENTS 
  3736.  
  3737. The row and column numbering is zero-based, so on a standard 25 line by 80 
  3738. column display, valid rows are 0 - 24 and valid columns are 0 - 79. 
  3739.  
  3740. SCREEN does not change the default screen colors.  To display text in specific 
  3741. colors, use SCRPUT. 
  3742.  
  3743. SCREEN checks for a valid row and column, and displays an error message if 
  3744. either value is out of range. 
  3745.  
  3746. See also ECHO, SCRPUT, TEXT, and VSCRPUT. 
  3747.  
  3748. EXAMPLE 
  3749.  
  3750. The following batch file fragment displays a menu: 
  3751.  
  3752.     @echo off
  3753.     cls
  3754.     screen 3 10 Select a number from 1 to 4:
  3755.     screen 6 20 1 - Word Processing
  3756.     screen 7 20 2 - Spreadsheet
  3757.     screen 8 20 3 - Telecommunications
  3758.     screen 9 20 4 - Quit
  3759.  
  3760.  
  3761. ΓòÉΓòÉΓòÉ 3.61. SCRPUT - Display text in color ΓòÉΓòÉΓòÉ
  3762.  
  3763. SYNTAX     (Internal 4OS2) 
  3764.  
  3765. SCRPUT row column [bright] [blink] fg ON bg text
  3766.  
  3767. PURPOSE 
  3768.  
  3769. Display text in color. 
  3770.  
  3771. COMMENTS 
  3772.  
  3773. The row and column numbering is zero-based, so on a standard 25 line by 80 
  3774. column display, valid rows are 0 - 24 and valid columns are 0 - 79. 
  3775.  
  3776. SCRPUT is similar to SCREEN, but allows you to specify the display colors, and 
  3777. writes directly to the screen. 
  3778.  
  3779. The parameters are: 
  3780.  
  3781.     row         Start row 
  3782.  
  3783.     column      Start column 
  3784.  
  3785.     fg          Foreground character color 
  3786.  
  3787.     bg          Background character color 
  3788.  
  3789.     text        The text to display 
  3790.  
  3791.  Only the first three characters of the color name and attributes ("bright" and 
  3792.  "blink") are required. 
  3793.  
  3794.  The available colors are: 
  3795.  
  3796.       Black      Blue      Green      Red
  3797.       Magenta    Cyan      Yellow     White
  3798.  
  3799.  See also ECHO, SCREEN, TEXT, and VSCRPUT. 
  3800.  
  3801.  EXAMPLE 
  3802.  
  3803.  The following batch file fragment displays a menu in color: 
  3804.  
  3805.       @echo off & cls white on blue
  3806.       scrput 3 10 bri white on blue Select a number from 1 to 4:
  3807.       scrput 6 20 bri red on blue 1 - Word Processing
  3808.       scrput 7 20 bri yellow on blue 2 - Spreadsheet
  3809.       scrput 8 20 bri green on blue 3 - Telecommunications
  3810.       scrput 9 20 bri magenta on blue 4 - Quit
  3811.  
  3812.  
  3813. ΓòÉΓòÉΓòÉ 3.62. SELECT - Select files for command ΓòÉΓòÉΓòÉ
  3814.  
  3815. SYNTAX     (Internal 4OS2) 
  3816.  
  3817. SELECT [/A[:-rhsda] /C /D /O:-deginrsu /Z] command ([path]filename)
  3818.  
  3819. PURPOSE 
  3820.  
  3821. Execute a command on the specified files. 
  3822.  
  3823. COMMENTS 
  3824.  
  3825. SELECT allows you to select command line file arguments by marking the files 
  3826. using a full-screen "point-and-shoot" display.  SELECT substitutes the selected 
  3827. files for the argument enclosed in parentheses, and executes the command for 
  3828. each marked file.  If you specify multiple arguments in the parentheses, SELECT 
  3829. will display the matching files for the first argument, prompt you to mark the 
  3830. files, execute the command for each marked file, and then continue the same 
  3831. procedure with the next argument. 
  3832.  
  3833. The SELECT options are: 
  3834.  
  3835.     /A      Display only those files that have the specified attribute set. 
  3836.             Preceding the attribute character with a '-' will display those 
  3837.             files that DON'T  have that attribute set.  Attributes can also be 
  3838.             combined.  The attributes are: 
  3839.               R  Read only 
  3840.               H  Hidden 
  3841.               S  System 
  3842.               D  Directory 
  3843.               A  Archive 
  3844.  
  3845.     /C      Display filenames in upper case. 
  3846.  
  3847.     /D      Disable directory colorization. 
  3848.  
  3849.     /O      Sort sequence, where ? can be any combination of the following: 
  3850.               -  Reverse the sort order for the next option 
  3851.               a  Sort by ASCII value rather than numeric value 
  3852.               d  Sort by date and time (oldest first) 
  3853.               e  Sort by extension 
  3854.               g  Group subdirectories together 
  3855.               i  Sort by the file description 
  3856.               n  Sort by the filename (this is the default) 
  3857.               r  Reverse the sort order for all options 
  3858.               s  Sort by size 
  3859.               u  Unsorted 
  3860.  
  3861.     /Z      Display HPFS volumes in FAT format, including file descriptions and 
  3862.             truncating filenames to 11 characters. 
  3863.  
  3864.  If you append filenames with a ; (an "include list"), SELECT will display the 
  3865.  matching filenames in a single listing.  Only the first filename in an include 
  3866.  list can have a path. 
  3867.  
  3868.  You can display the file and subdirectory names in color by setting the 
  3869.  COLORDIR variable.  The format for COLORDIR is: 
  3870.  
  3871.       ext [...]:[bright][blink] fg [ON bg]; ...
  3872.  
  3873.  where "ext" is the file extension, or one of the following file attributes: 
  3874.  
  3875.       DIRS - directory
  3876.       RDONLY - read-only file
  3877.       HIDDEN - hidden file
  3878.       SYSTEM - system file
  3879.       ARCHIVE - file modified since last backup
  3880.  
  3881.  For example, to display the .COM and .EXE files in red, the .C and .ASM files 
  3882.  in bright cyan, and the read-only files in blinking green: 
  3883.  
  3884.       set colordir=com exe:red; c asm:bright cyan; rdonly:blink green
  3885.  
  3886.  If you don't select a background color, SELECT will use the current screen 
  3887.  background color. 
  3888.  
  3889.  If you enclose the arguments in square brackets [ ] rather than parentheses, 
  3890.  SELECT will insert all of the arguments into the command line and only execute 
  3891.  the command once.  You must be careful not to exceed the maximum line length 
  3892.  (1023 characters). 
  3893.  
  3894.  SELECT uses the cursor up, cursor down, PgUp, and PgDn keys to scroll through 
  3895.  the files matching the argument(s).  Use the + key to select a file, and the - 
  3896.  key to unselect a file.  The * key will reverse all of the current marks 
  3897.  (excluding subdirectories), and the / key will unmark everything.  After 
  3898.  marking the files, press ENTER to execute the command. You can select a single 
  3899.  file by moving the scroll bar to the filename and pressing ENTER. 
  3900.  
  3901.  To cancel the SELECT command, type an Escape, ^C, or ^BREAK. 
  3902.  
  3903.  EXAMPLES 
  3904.  
  3905.  Select from the files in the current directory with the extension .COM, and 
  3906.  then from the files with the extension .EXE to copy to the root directory on 
  3907.  drive A: 
  3908.  
  3909.       select copy (*.com *.exe) a:\
  3910.  
  3911.  Select and run an executable program (.COM or .EXE) from files in the C:\UTIL 
  3912.  directory (an "include list"): 
  3913.  
  3914.       select (c:\util\*.com;*.exe)
  3915.  
  3916.  
  3917. ΓòÉΓòÉΓòÉ 3.63. SET - Display / set environment variables ΓòÉΓòÉΓòÉ
  3918.  
  3919. SYNTAX     (Internal 4OS2) 
  3920.  
  3921. SET [/P] [/R [d:][path]filename...] [variable=[value]]
  3922.  
  3923. PURPOSE 
  3924.  
  3925. Display, create, modify, or delete environment variables. 
  3926.  
  3927. COMMENTS 
  3928.  
  3929. Entering SET with no variable or value displays the entire environment.  If you 
  3930. don't enter a value, SET will display the value of that variable. Otherwise, 
  3931. the variable and value are placed in the environment.  If the variable already 
  3932. exists, its old contents are replaced by the new value. Variable names are 
  3933. limited to a maximum of 80 characters, and the value to a maximum of 255 
  3934. characters.  The variable names are shifted to upper case before being stored 
  3935. in the environment; the value is stored exactly as entered. 
  3936.  
  3937. The SET options are: 
  3938.  
  3939.     /P      Pause after displaying a page of environment entries. Press ^C to 
  3940.             quit, or any other key to display the next page. 
  3941.  
  3942.     /R      Read environment variables from a file.  This is much faster than 
  3943.             loading variables in a batch file.  The file is in the same format 
  3944.             as the SET display, so SET /R can accept as input a file generated 
  3945.             by redirecting SET output. 
  3946.  
  3947.  For example, the following commands will save the environment variables to a 
  3948.  file, and then reload them from that file: 
  3949.  
  3950.       set > varlist
  3951.       set /r varlist
  3952.  
  3953.  You can load variables from multiple files by listing the filenames 
  3954.  individually after the /R. 
  3955.  
  3956.  You can add comments to a variable file by starting the comment line with a 
  3957.  colon (:). 
  3958.  
  3959.  You can remove multiple environment variables with the UNSET command, and edit 
  3960.  environment variables with the ESET command. 
  3961.  
  3962.  See also ESET and UNSET. 
  3963.  
  3964.  EXAMPLES 
  3965.  
  3966.  Display the current environment: 
  3967.  
  3968.       set
  3969.  
  3970.  Add a variable to the environment: 
  3971.  
  3972.       set mine=c:\finance\myfiles
  3973.  
  3974.  Remove a variable from the environment: 
  3975.  
  3976.       set mine=
  3977.  
  3978.  
  3979. ΓòÉΓòÉΓòÉ 3.64. SETDOS - Display / set configuration options ΓòÉΓòÉΓòÉ
  3980.  
  3981. SYNTAX     (Internal 4OS2) 
  3982.  
  3983. SETDOS [/C? /E? /I+|-command /M? /P? /N? /R? /S?:? /U? /V?]
  3984.  
  3985. PURPOSE 
  3986.  
  3987. Display or set 4OS2 configuration options. 
  3988.  
  3989. COMMENTS 
  3990.  
  3991. Most of these options can also be set in 4OS2.INI. The name of the 
  3992. corresponding 4OS2.INI directive for each option, if any, is listed in square 
  3993. brackets [ ] at the end of the description for the option. Use SETDOS rather 
  3994. than 4OS2.INI when you need to make temporary changes. 
  3995.  
  3996. The SETDOS options are: 
  3997.  
  3998.     /C      The COMPOUND option sets the character used for separating multiple 
  3999.             commands on the same line.  The default character is the ampersand 
  4000.             (&).  You cannot use any of the redirection characters (|><), or 
  4001.             the whitespace characters (blank, tab, comma, semicolon, or equal) 
  4002.             as the command separator.  [CommandSep] 
  4003.  
  4004.     /E      The ESCAPE option sets the character used to suppress the normal 
  4005.             meaning of the following character.  Any character following the 
  4006.             escape character will be passed unmodified to the command line. 
  4007.             The default escape character is the caret (^).  You cannot use any 
  4008.             of the redirection characters (|><) or the whitespace characters 
  4009.             (blank, tab, comma, semicolon, or equal) as the escape character. 
  4010.             [EscapeChar] 
  4011.  
  4012.     /I      The INTERNAL option allows you to disable or enable internal 4OS2 
  4013.             commands.  To disable a command, precede the command name with a 
  4014.             minus (-).  To reenable a command, precede it with a plus (+). 
  4015.  
  4016.     /M      The MODE option controls the line editing mode. The default is 
  4017.             overstrike mode (/M0).  If MODE is set to 1, the default is insert 
  4018.             mode.  [EditMode] 
  4019.  
  4020.     /N      The NOCLOBBER option controls output redirection.  If NOCLOBBER is 
  4021.             set to 1, existing files may not be destroyed by output 
  4022.             redirection, and when appending with >>, the output file must 
  4023.             exist.  NOCLOBBER can be overridden with the ! character.  The 
  4024.             default value is 0.  [NoClobber] 
  4025.  
  4026.     /P      The PARAMETER option sets the character used to specify argument 
  4027.             lists in alias and variable expansion.  The default character is $ 
  4028.             (in 4DOS it is &).  [ParameterChar] 
  4029.  
  4030.     /R      The ROWS option determines the number of screen rows used by the 
  4031.             video display.  Normally 4OS2 detects the screen size, but if you 
  4032.             have a non-standard display you may need to set it explicitly.  The 
  4033.             ROWS option does not affect screen scrolling (that is controlled by 
  4034.             your video BIOS and OS/2); it is used only for LIST, SELECT, the 
  4035.             paged output options (i.e., TYPE /P), and error checking in the 
  4036.             screen output commands.  [ScreenRows] 
  4037.  
  4038.     /S      The SHAPE option sets the default cursor shape. The format is 
  4039.             /So:i, where "o" is the cursor size for overstrike mode, and "i" 
  4040.             the cursor size for insert mode.  The size is entered as a 
  4041.             percentage of the total character cell size.  The default values 
  4042.             are 10:100 (a thin underscore cursor for overstrike mode, and a 
  4043.             block cursor for insert mode).  Because of the way video BIOSes 
  4044.             remap the cursor, you may not get a smooth progression in the 
  4045.             cursor size from 0 - 100%. To disable the cursor, use /S0:0. 
  4046.             [CursorOver, CursorIns] 
  4047.  
  4048.     /U      The UPPER option controls the way filenames are displayed for the 
  4049.             internal commands (COPY, DIR, etc.).  If UPPER is 1, filenames will 
  4050.             be displayed in upper case.  The default is /U0 (filenames will be 
  4051.             displayed in lower case).  [UpperCase] 
  4052.  
  4053.     /V      The VERBOSE option controls command echoing in batch files.  If 
  4054.             VERBOSE is set to 0, batch files will NOT be echoed unless ECHO is 
  4055.             set ON.  The default is 1 (batch file commands WILL be echoed).  If 
  4056.             VERBOSE is set to 2, all batch file lines will be echoed, including 
  4057.             those prefaced by a '@', and when ECHO is OFF.  [BatchEcho] 
  4058.  
  4059.  EXAMPLES 
  4060.  
  4061.  Change the COMPOUND character to a ~ (tilde): 
  4062.  
  4063.       setdos /c~
  4064.  
  4065.  Change MODE to insert, VERBOSE to off, and set NOCLOBBER on: 
  4066.  
  4067.       setdos /m1 /v0 /n1
  4068.  
  4069.  Disable the internal LIST command: 
  4070.  
  4071.       setdos /i-list
  4072.  
  4073.  Change the the PARAMETER character to an &, the COMPOUND character to a ^, and 
  4074.  the ESCAPE character to a  (ctrl-X), so that 4OS2 syntax matches that used in 
  4075.  4DOS.  Note the ^ escape characters used before the new parameter and compound 
  4076.  characters.  These prevent the new characters from being given their old 
  4077.  meanings within the SETDOS command; for example, without them the & would be 
  4078.  taken as the end of the SETDOS command. 
  4079.  
  4080.       setdos /p^& /c^^ /e
  4081.  
  4082.  
  4083. ΓòÉΓòÉΓòÉ 3.65. SETLOCAL - Save environment ΓòÉΓòÉΓòÉ
  4084.  
  4085. SYNTAX     (Internal 4OS2) 
  4086.  
  4087. SETLOCAL
  4088.  
  4089. PURPOSE 
  4090.  
  4091. Save a copy of the current disk drive, directory, aliases, and environment 
  4092. variables. 
  4093.  
  4094. COMMENTS 
  4095.  
  4096. SETLOCAL is used in batch files to save the disk drive, directory, aliases, and 
  4097. environment variables to a reserved block of memory.  You can then change their 
  4098. values, and later restore the original values with ENDLOCAL.  You cannot use 
  4099. SETLOCAL in an alias. 
  4100.  
  4101. SETLOCAL and ENDLOCAL are not nestable within the same batch file. However, you 
  4102. can have multiple SETLOCAL / ENDLOCAL pairs within a batch file, and nested 
  4103. batch files can each have their own SETLOCAL / ENDLOCAL. An ENDLOCAL will be 
  4104. automatically performed at the end of a batch file. 
  4105.  
  4106. Note that if you invoke a batch from another without using CALL, the first 
  4107. batch file is implicitly terminated, and an automatic ENDLOCAL performed. The 
  4108. second batch file will inherit the drive, directory, aliases, and environment 
  4109. variables as they were prior to the SETLOCAL. 
  4110.  
  4111. See also ENDLOCAL. 
  4112.  
  4113. EXAMPLE 
  4114.  
  4115. This batch file fragment saves the disk drive, directory, aliases, and 
  4116. environment variables, changes the disk and directory, modifies some variables, 
  4117. runs a program, and then restores the original values: 
  4118.  
  4119.     setlocal
  4120.     cdd d:\test & set path=c:\;c:\os;c:\util & set lib=d:\lib
  4121.     rem run some program here
  4122.     endlocal
  4123.  
  4124.  
  4125. ΓòÉΓòÉΓòÉ 3.66. SHIFT - Shift batch arguments ΓòÉΓòÉΓòÉ
  4126.  
  4127. SYNTAX     (Internal 4OS2) 
  4128.  
  4129. SHIFT [n]
  4130.  
  4131. PURPOSE 
  4132.  
  4133. Allow the use of more than 10 variables in a batch file. 
  4134.  
  4135. COMMENT 
  4136.  
  4137. SHIFT is provided for compatibility with CMD.EXE, which only supports 10 
  4138. parameters (%0 through %9); 4OS2 supports 128 (%0 to %127), so you may not need 
  4139. to use SHIFT for batch files running exclusively under 4OS2. 
  4140.  
  4141. SHIFT moves each batch file parameter n positions (i.e., if n is 1, then %1 
  4142. becomes %0, %2 becomes %1, etc.).  The default value for n is 1.  You can also 
  4143. reverse a SHIFT by giving a negative value for n (i.e., if n is -1, the former 
  4144. value for %0 is restored, %1 becomes %1, %1 becomes %2, etc.). 
  4145.  
  4146. SHIFT also affects the %$ (command line tail) and %# (number of command 
  4147. arguments) batch variables. 
  4148.  
  4149. EXAMPLES 
  4150.  
  4151. Create a batch file called TEST.BTM: 
  4152.  
  4153.     echo %1 %2 %3 %4
  4154.     shift
  4155.     echo %1 %2 %3 %4
  4156.     shift 2
  4157.     echo %1 %2 %3 %4
  4158.     shift -1
  4159.     echo %1 %2 %3 %4
  4160.  
  4161. Executing TEST.BTM with the arguments "zero one two three four five six" 
  4162. produces the following results: 
  4163.  
  4164.     zero one two three
  4165.     one two three four
  4166.     three four five six
  4167.     two three four five
  4168.  
  4169.  
  4170. ΓòÉΓòÉΓòÉ 3.67. START - Start new session ΓòÉΓòÉΓòÉ
  4171.  
  4172. SYNTAX     (Internal 4OS2) 
  4173.  
  4174. START ["title"] [/B[G] /C /DOS[=filename] /F[G] /FS /I /ICON=name
  4175.     /INV /K /L /MAX /MIN /N /PGM /PM /POS=x,y,x1,y1 /WAIT /WIN]
  4176.     [command ...]
  4177.  
  4178. PURPOSE 
  4179.  
  4180. Start a program in a new OS/2 session. 
  4181.  
  4182. COMMENTS 
  4183.  
  4184. Entering START with no program name starts another 4OS2 session. 
  4185.  
  4186. START determines the application type automatically and starts it in the 
  4187. appropriate mode (full-screen, windowed, or PM).  If the program is a DOS app 
  4188. or Windows 3.x app, 4OS2 will either return an error message (in OS/2 1.3), or 
  4189. start the program in a VDM (in OS/2 2.0). 
  4190.  
  4191. You cannot start a batch file (.CMD or .BTM) with /PM; use /FS or /WIN. 
  4192.  
  4193. The START options are: 
  4194.  
  4195.     "title"     Specify the title to appear on the title bar and in the PM task 
  4196.                 list.  The title must be enclosed in double quotes and cannot 
  4197.                 exceed 60 characters.  If you don't specify a title, the 
  4198.                 program name is used. 
  4199.  
  4200.     /B[G]       Start as a background session. 
  4201.  
  4202.     /C          Start the application in a 4OS2 session, and end the session 
  4203.                 when the application finishes. 
  4204.  
  4205.     /DOS        (OS/2 2.0 only) Start a foreground DOS session. 
  4206.  
  4207.     /DOS=filename[4OS2/32 only]  Start a foreground DOS session with DOS 
  4208.                 settings from the specified file.  Each line in the file should 
  4209.                 have a name, an equal sign (=), and a value.  The names are 
  4210.                 those shown in OS/2's standard DOS Settings dialog box, for 
  4211.                 example: 
  4212.  
  4213.                                         DOS_BREAK=ON
  4214.                                         DOS_LASTDRIVE=N
  4215.                                         DOS_RMSIZE=640
  4216.  
  4217.                 Note that the valid settings can depend on what device drivers 
  4218.                 you have loaded on your system, and DOS settings that are valid 
  4219.                 on one system may not be valid on another.  Some 
  4220.                 experimentation may be required, as DOS settings often are not 
  4221.                 documented by IBM or device driver manufacturers. 
  4222.  
  4223.                 START will use the default DOS parameters for any options that 
  4224.                 aren't specified in the settings file.  You can add comments to 
  4225.                 the file by beginning the line with a colon (:). 
  4226.  
  4227.     /F[G]       Start the session in the foreground.  The default is to start 
  4228.                 in the background, unless you specify /DOS, /FS, /WIN, or /PM. 
  4229.  
  4230.     /FS         Start a foreground full-screen session. 
  4231.  
  4232.     /I          Inherit the environment specified by the SET statements in 
  4233.                 CONFIG.SYS, rather than the current 4OS2 environment. 
  4234.  
  4235.     /ICON       Use the specified icon file. 
  4236.  
  4237.     /INV        Start the session as invisible (no icon; only accessible 
  4238.                 through the Task Manager or Window List). 
  4239.  
  4240.     /K          Start the application in a 4OS2 session, and keep the session 
  4241.                 when the application finishes.  This is the default for all 
  4242.                 non-PM applications. 
  4243.  
  4244.     /L          Start 4OS2 with local alias and history lists. 
  4245.  
  4246.     /MAX        Start the session maximized. 
  4247.  
  4248.     /MIN        Start the session minimized. 
  4249.  
  4250.     /N          Start the program directly without using 4OS2.EXE.  The command 
  4251.                 cannot be a batch file or internal command.  This is the 
  4252.                 default value for PM applications. 
  4253.  
  4254.     /PGM        The next argument is the program name, not a session name. 
  4255.  
  4256.     /PM         Start a foreground PM application. 
  4257.  
  4258.     /POS        Specify the start position (x,y), and the window size (x1,y1) 
  4259.                 in pels (the lower left corner is 0,0). 
  4260.  
  4261.     /WAIT       Start the session as a child session, and wait for it to end 
  4262.                 before continuing. 
  4263.  
  4264.     /WIN        Start a foreground windowed session. 
  4265.  
  4266.  If you specify a session type incompatible with the program (for example, a 
  4267.  /PM with a .CMD file), START will start the session in the default mode for 
  4268.  that program. 
  4269.  
  4270.  See also DETACH 
  4271.  
  4272.  EXAMPLES 
  4273.  
  4274.  Start a full-screen 4OS2 session: 
  4275.  
  4276.       start /fs
  4277.  
  4278.  Start 4DOS in a windowed DOS session (OS/2 2.0 only): 
  4279.  
  4280.       start /dos /win 4DOS.COM
  4281.  
  4282.  (The "4DOS.COM" in this example is optional.  4OS2 will start 4DOS 
  4283.  automatically if no program name is given in a START /DOS command and 4DOS is 
  4284.  your default DOS command processor.) 
  4285.  
  4286.  Start CHKDSK in a minimized background window session, without using 4OS2, and 
  4287.  with the title "Analyzing the disk": 
  4288.  
  4289.       start "Analyzing the disk" /bg /min /win /n chkdsk
  4290.  
  4291.  
  4292. ΓòÉΓòÉΓòÉ 3.68. TEE - Tee pipe fitting ΓòÉΓòÉΓòÉ
  4293.  
  4294. SYNTAX     (Internal 4OS2) 
  4295.  
  4296. TEE [/A] [d:][path]filename...
  4297.  
  4298. PURPOSE 
  4299.  
  4300. Copy standard input to standard output, and save a copy in the specified 
  4301. file(s). 
  4302.  
  4303. COMMENTS 
  4304.  
  4305. The only option for TEE is: 
  4306.  
  4307.     /A      Append output to the file(s) rather than overwriting it. 
  4308.  
  4309.  If you are typing at the keyboard, enter a ^Z to terminate the input. 
  4310.  
  4311.  TEE is often used to save the intermediate output of a pipe. 
  4312.  
  4313.  See also Y. 
  4314.  
  4315.  EXAMPLE 
  4316.  
  4317.  Search the file DOC for any lines containing the string "486", make a copy of 
  4318.  the matching lines in 4.DAT, and write them to the output file 486.DAT: 
  4319.  
  4320.       find "486" doc | tee 4.dat | sort > 486.dat
  4321.  
  4322.  
  4323. ΓòÉΓòÉΓòÉ 3.69. TEXT - Display text block ΓòÉΓòÉΓòÉ
  4324.  
  4325. SYNTAX     (Internal 4OS2) 
  4326.  
  4327. TEXT
  4328.  .
  4329.  .
  4330.  .
  4331. ENDTEXT
  4332.  
  4333. PURPOSE 
  4334.  
  4335. Display a block of text in a batch file. 
  4336.  
  4337. COMMENTS 
  4338.  
  4339. The TEXT command is useful for displaying menus or multiple-line messages. TEXT 
  4340. will display subsequent lines in the text until terminated by ENDTEXT. Both 
  4341. TEXT and ENDTEXT must be entered as the only command on that line. 
  4342.  
  4343. You can change screen colors by inserting ANSI escape sequences into the text 
  4344. block. 
  4345.  
  4346. If the output of TEXT is redirected, all lines in the text block will be 
  4347. written to the specified output file, and not to the screen. 
  4348.  
  4349. See also ECHO, SCREEN, SCRPUT, and VSCRPUT. 
  4350.  
  4351. EXAMPLE 
  4352.  
  4353. The following batch file fragment displays a simple menu: 
  4354.  
  4355.     @echo off & cls & screen 2 0
  4356.     text
  4357.     Enter one of the following:
  4358.  
  4359.         1 - Spreadsheet
  4360.         2 - Word Processing
  4361.         3 - DOS Utilities
  4362.  
  4363.     Enter your selection:
  4364.     endtext
  4365.  
  4366.  
  4367. ΓòÉΓòÉΓòÉ 3.70. TIME - Set/Display time ΓòÉΓòÉΓòÉ
  4368.  
  4369. SYNTAX     (Internal 4OS2) 
  4370.  
  4371. TIME [hh:mm:ss]
  4372.  
  4373. PURPOSE 
  4374.  
  4375. Display or set the current system time. 
  4376.  
  4377. COMMENTS 
  4378.  
  4379. If you don't enter any parameters, TIME will display the current system time 
  4380. and prompt you for a new time.  Press ENTER if you don't wish to change the 
  4381. time, otherwise enter the new time. 
  4382.  
  4383. The parameters for the TIME command are: 
  4384.  
  4385.     hh      Hour (0 - 23) 
  4386.     mm      Minute (0 - 59) 
  4387.     ss      Second (0 - 59) 
  4388.  
  4389.  TIME defaults to 24-hour format; you can optionally enter the time in 12-hour 
  4390.  format by appending an "am" or "pm". 
  4391.  
  4392.  Whenever you create or modify a file, the system time is recorded in the 
  4393.  directory entry. 
  4394.  
  4395.  See also DATE, and TIMER. 
  4396.  
  4397.  EXAMPLES 
  4398.  
  4399.  Enter the time (9:30 am): 
  4400.  
  4401.       time 9:30
  4402.  
  4403.  To be prompted for the time: 
  4404.  
  4405.       time
  4406.  
  4407.  
  4408. ΓòÉΓòÉΓòÉ 3.71. TIMER - System stopwatch ΓòÉΓòÉΓòÉ
  4409.  
  4410. SYNTAX     (Internal 4OS2) 
  4411.  
  4412. TIMER [/1 /2 /3 /S] [ON]
  4413.  
  4414. PURPOSE 
  4415.  
  4416. System stopwatch. 
  4417.  
  4418. COMMENTS 
  4419.  
  4420. The TIMER command turns an internal stopwatch on and off.  The first time you 
  4421. run TIMER, the stopwatch starts.  When you run TIMER again, the stopwatch stops 
  4422. and the elapsed time is displayed.  There are three timers available (1, 2, and 
  4423. 3), so you can time multiple overlapping events.  The default timer is #1. 
  4424.  
  4425. The options for TIMER are: 
  4426.  
  4427.     ON      Force the timer to restart 
  4428.  
  4429.     /1      Use timer #1 
  4430.  
  4431.     /2      Use timer #2 
  4432.  
  4433.     /3      Use timer #3 
  4434.  
  4435.     /S      Display split time without stopping the timer 
  4436.  
  4437.  TIMER is particularly useful for timing events in batch files. 
  4438.  
  4439.  The smallest interval TIMER can measure 0.03 seconds; the largest interval is 
  4440.  23:59:59.99. 
  4441.  
  4442.  See also TIME. 
  4443.  
  4444.  EXAMPLES 
  4445.  
  4446.  Start or stop the timer: 
  4447.  
  4448.       timer
  4449.  
  4450.  Display a split time: 
  4451.  
  4452.       timer /s
  4453.  
  4454.  
  4455. ΓòÉΓòÉΓòÉ 3.72. TYPE - Display files ΓòÉΓòÉΓòÉ
  4456.  
  4457. SYNTAX     (Internal 4OS2) 
  4458.  
  4459. TYPE [/L /P] [d:][pathname]filename...
  4460.  
  4461. PURPOSE 
  4462.  
  4463. Display the contents of the specified file(s). 
  4464.  
  4465. COMMENTS 
  4466.  
  4467. The TYPE command displays a file.  Press ^S to suspend the display, and any 
  4468. character key to continue the display. 
  4469.  
  4470. The TYPE options are: 
  4471.  
  4472.     /L      Print line numbers preceding each line of text. 
  4473.  
  4474.     /P      Pause after each page.  Press ^C to quit, or any other key to 
  4475.             display the next page. 
  4476.  
  4477.  TYPE is normally only useful for displaying ASCII text files; executable files 
  4478.  (.COM and .EXE) and many data files will be unreadable due to the presence of 
  4479.  non-alphanumeric characters. 
  4480.  
  4481.  You will probably find LIST to be more useful for displaying files. 
  4482.  
  4483.  See also LIST. 
  4484.  
  4485.  EXAMPLE 
  4486.  
  4487.  Display the files MEMO1 and MEMO2, pausing at the end of each page: 
  4488.  
  4489.       type /p memo1 memo2
  4490.  
  4491.  
  4492. ΓòÉΓòÉΓòÉ 3.73. UNALIAS - Remove aliases ΓòÉΓòÉΓòÉ
  4493.  
  4494. SYNTAX     (Internal 4OS2) 
  4495.  
  4496. UNALIAS [/Q] alias...
  4497. UNALIAS *
  4498.  
  4499. PURPOSE 
  4500.  
  4501. Remove aliases from the alias list. 
  4502.  
  4503. COMMENTS 
  4504.  
  4505. UNALIAS also accepts the wildcard character * to delete all aliases. 
  4506.  
  4507. The only option for UNALIAS is: 
  4508.  
  4509.     /Q      Don't display an error message if the alias doesn't exist. 
  4510.  
  4511.  See also ALIAS and ESET. 
  4512.  
  4513.  EXAMPLES 
  4514.  
  4515.  Remove the alias DDIR: 
  4516.  
  4517.       unalias ddir
  4518.  
  4519.  Remove the aliases DDIR and ZAP: 
  4520.  
  4521.       unalias ddir zap
  4522.  
  4523.  Remove all the aliases: 
  4524.  
  4525.       unalias *
  4526.  
  4527.  
  4528. ΓòÉΓòÉΓòÉ 3.74. UNSET - Remove environment variables ΓòÉΓòÉΓòÉ
  4529.  
  4530. SYNTAX     (Internal 4OS2) 
  4531.  
  4532. UNSET [/Q] name...
  4533. UNSET *
  4534.  
  4535. PURPOSE 
  4536.  
  4537. Remove variables from the environment. 
  4538.  
  4539. COMMENTS 
  4540.  
  4541. UNSET also accepts the wildcard character * to delete all environment 
  4542. variables.  Use caution with UNSET *; many programs are dependent on 
  4543. environment variables.  (4OS2 relies on PATH and COMSPEC.) 
  4544.  
  4545. The only option for UNSET is: 
  4546.  
  4547.     /Q      Don't display an error message if the environment variable doesn't 
  4548.             exist. 
  4549.  
  4550.  UNSET is often used in conjunction with SETLOCAL / ENDLOCAL in order to clear 
  4551.  the environment of variables that may cause problems for some applications. 
  4552.  
  4553.  See also ESET and SET. 
  4554.  
  4555.  EXAMPLES 
  4556.  
  4557.  Remove the variable CMDLINE: 
  4558.  
  4559.       unset cmdline
  4560.  
  4561.  Remove the variables CMDLINE and PATH: 
  4562.  
  4563.       unset cmdline path
  4564.  
  4565.  Remove all the environment variables: 
  4566.  
  4567.       unset *
  4568.  
  4569.  
  4570. ΓòÉΓòÉΓòÉ 3.75. VER - Display 4OS2 and OS/2 versions ΓòÉΓòÉΓòÉ
  4571.  
  4572. SYNTAX     (Internal 4OS2) 
  4573.  
  4574. VER [/R]
  4575.  
  4576. PURPOSE 
  4577.  
  4578. Display the current 4OS2 and OS/2 versions. 
  4579.  
  4580. COMMENTS 
  4581.  
  4582. The 4OS2 and OS/2 versions consist of a one digit major version number, a 
  4583. period, and a one or two digit minor version number. 
  4584.  
  4585. The only option for VER is: 
  4586.  
  4587.     /R      Display the OS/2 and 4OS2 revision levels. 
  4588.  
  4589.  EXAMPLE 
  4590.  
  4591.  Get the current version of 4OS2 and OS/2: 
  4592.  
  4593.       ver
  4594.  
  4595.  
  4596. ΓòÉΓòÉΓòÉ 3.76. VERIFY - Set disk write verification ΓòÉΓòÉΓòÉ
  4597.  
  4598. SYNTAX     (Internal 4OS2) 
  4599.  
  4600. VERIFY [on | off]
  4601.  
  4602. PURPOSE 
  4603.  
  4604. Display, enable, or disable disk write verification. 
  4605.  
  4606. COMMENTS 
  4607.  
  4608. When VERIFY is ON, the system will verify that no error occurred during each 
  4609. disk write operation.  It does NOT compare the data actually written to the 
  4610. disk.  VERIFY will remain ON until you set it OFF. 
  4611.  
  4612. Entering VERIFY with no parameters will display the current VERIFY state. 
  4613.  
  4614. Verification will slow your disk write operations slightly. 
  4615.  
  4616. At system startup, VERIFY is OFF. 
  4617.  
  4618. EXAMPLES 
  4619.  
  4620. Check the current verify status: 
  4621.  
  4622.     verify
  4623.  
  4624. Enable disk write verification: 
  4625.  
  4626.     verify on
  4627.  
  4628.  
  4629. ΓòÉΓòÉΓòÉ 3.77. VOL - Display volume labels ΓòÉΓòÉΓòÉ
  4630.  
  4631. SYNTAX     (Internal 4OS2) 
  4632.  
  4633. VOL [d:] ...
  4634.  
  4635. PURPOSE 
  4636.  
  4637. Display the disk volume label(s). 
  4638.  
  4639. COMMENTS 
  4640.  
  4641. If you don't enter a drive name, VOL displays the disk label and the volume 
  4642. serial number for the current drive. 
  4643.  
  4644. If the disk doesn't have a volume name, VOL will report it as "unlabeled." 
  4645.  
  4646. Volume labels can be created, changed or deleted with the LABEL command. 
  4647.  
  4648. EXAMPLE 
  4649.  
  4650. Display the disk labels for drives A and B: 
  4651.  
  4652.     vol a: b:
  4653.  
  4654.  
  4655. ΓòÉΓòÉΓòÉ 3.78. VSCRPUT - Write vertical text ΓòÉΓòÉΓòÉ
  4656.  
  4657. SYNTAX     (Internal 4OS2) 
  4658.  
  4659. VSCRPUT row column [bright] [blink] fg ON bg text
  4660.  
  4661. PURPOSE 
  4662.  
  4663. Display text in color in a vertical column. 
  4664.  
  4665. COMMENTS 
  4666.  
  4667. The row and column numbering is zero-based, so on a standard 25 row by 80 
  4668. column display, valid rows are 0 - 24 and valid columns are 0 - 79. 
  4669.  
  4670. VSCRPUT works like SCRPUT, but writes the text vertically. 
  4671.  
  4672. The parameters are: 
  4673.  
  4674.     row         Start row 
  4675.  
  4676.     column      Start column 
  4677.  
  4678.     fg          Foreground character color 
  4679.  
  4680.     bg          Background character color 
  4681.  
  4682.     text        The text to display 
  4683.  
  4684.  Only the first three characters of the color name and attributes ("bright" and 
  4685.  "blink") are required. 
  4686.  
  4687.  The available colors are: 
  4688.  
  4689.       Black      Blue      Green      Red
  4690.       Magenta    Cyan      Yellow     White
  4691.  
  4692.  See also ECHO, SCREEN, SCRPUT, and TEXT. 
  4693.  
  4694.  EXAMPLE 
  4695.  
  4696.  The following batch file fragment displays an X and Y axis and labels them: 
  4697.  
  4698.       drawhline 20 10 40 1 bright white on blue
  4699.       drawvline 2 10 18 1 bright white on blue
  4700.       scrput 21 20 bright red on blue X axis
  4701.       vcrput 8 9 bright red on blue Y axis
  4702.  
  4703.  
  4704. ΓòÉΓòÉΓòÉ 3.79. WINDOW - Set the window title and state ΓòÉΓòÉΓòÉ
  4705.  
  4706. SYNTAX     (Internal 4OS2) 
  4707.  
  4708. WINDOW ["title"] MINimize | MAXimize | REStore
  4709.  
  4710. PURPOSE 
  4711.  
  4712. Change the title and / or state of the current 4OS2 window. 
  4713.  
  4714. COMMENTS 
  4715.  
  4716. WINDOW works only in windowed OS/2 sessions. 
  4717.  
  4718. The minimize, maximize, and restore parameters may be abbreviated by their 
  4719. first three letters. 
  4720.  
  4721. The window options (other than "title") are equivalent to the similarly named 
  4722. options on the system menu (the menu which appears when you click on the box in 
  4723. the top left corner of a window). 
  4724.  
  4725. The parameters are: 
  4726.  
  4727.     "title"         Change the window title.  Setting the title at the command 
  4728.                     prompt changes it permanently (or until WINDOW "title" is 
  4729.                     used to change it again); setting it in a batch file 
  4730.                     changes it only for the duration of the batch file. 
  4731.  
  4732.     MINimize        Minimize the 4OS2 window. 
  4733.  
  4734.     MAXimize        Maximize the 4OS2 window. 
  4735.  
  4736.     REStore         Restore the 4OS2 window to its "normal" size (the size 
  4737.                     before it was minimized or maximized). 
  4738.  
  4739.  EXAMPLE 
  4740.  
  4741.  This batch file fragment minimizes the current window, performs some 
  4742.  operations, then restores the window to its original size (not maximized or 
  4743.  minimized): 
  4744.  
  4745.       window minimize
  4746.       dir
  4747.       memory
  4748.       window restore
  4749.  
  4750.  
  4751. ΓòÉΓòÉΓòÉ 3.80. Y - Y pipe fitting ΓòÉΓòÉΓòÉ
  4752.  
  4753. SYNTAX     (Internal 4OS2) 
  4754.  
  4755. Y [d:][path]filename...
  4756.  
  4757. PURPOSE 
  4758.  
  4759. Copy standard input to standard output, and then copy the specified file(s) to 
  4760. standard output. 
  4761.  
  4762. COMMENTS 
  4763.  
  4764. Standard input from the console is terminated by a ^Z. 
  4765.  
  4766. See also TEE. 
  4767.  
  4768. EXAMPLE 
  4769.  
  4770. Get text from standard input, append the files MEMO1 and MEMO2 to it, and send 
  4771. the output to MEMOS: 
  4772.  
  4773.     y memo1 memo2 > memos
  4774.  
  4775.  
  4776. ΓòÉΓòÉΓòÉ 4. 4OS2 Reference tables ΓòÉΓòÉΓòÉ
  4777.  
  4778. This section includes an ASCII character table, an ANSI command reference, and 
  4779. a list of the keycodes used by INKEY. 
  4780.  
  4781.  
  4782. ΓòÉΓòÉΓòÉ 4.1. ASCII table ΓòÉΓòÉΓòÉ
  4783.  
  4784.                       Control Characters
  4785.  
  4786.     Dec  Hex  Chr  Nam  Ctl   Γöé   Dec  Hex  Chr  Nam  Ctl
  4787.     ---  ---  ---  ---  ---   Γöé   ---  ---  ---  ---  ---
  4788.     000   00       NUL   ^@   Γöé   016   10      DLE   ^P
  4789.     001   01      SOH   ^A   Γöé   017   11      DC1   ^Q
  4790.     002   02      STX   ^B   Γöé   018   12      DC2   ^R
  4791.     003   03      ETX   ^C   Γöé   019   13      DC3   ^S
  4792.     004   04      EOT   ^D   Γöé   020   14      DC4   ^T
  4793.     005   05      ENQ   ^E   Γöé   021   15      NAK   ^U
  4794.     006   06      ACK   ^F   Γöé   022   16      SYN   ^V
  4795.     007   07       BEL   ^G   Γöé   023   17      ETB   ^W
  4796.     008   08      BS    ^H   Γöé   024   18      CAN   ^X
  4797.     009   09       HT    ^I   Γöé   025   19      EM    ^Y
  4798.     010   0A       LF    ^J   Γöé   026   1A      SUB   ^Z
  4799.     011   0B       VT    ^K   Γöé   027   1B      ESC   ^[
  4800.     012   0C       FF    ^L   Γöé   028   1C      FS    ^\
  4801.     013   0D       CR    ^M   Γöé   029   1D      GS    ^]
  4802.     014   0E      SO    ^N   Γöé   030   1E      RS    ^^
  4803.     015   0F      SI    ^O   Γöé   031   1F      US    ^_
  4804.  
  4805.                   Punctuation, Digits, Upper Case
  4806.  
  4807.   Dec  Hex  Chr Γöé  Dec  Hex  Chr Γöé  Dec  Hex  Chr Γöé  Dec  Hex  Chr
  4808.   ---  ---  --- Γöé  ---  ---  --- Γöé  ---  ---  --- Γöé  ---  ---  ---
  4809.   032   20      Γöé  048   30   0  Γöé  064   40   @  Γöé  080   50   P
  4810.   033   21   !  Γöé  049   31   1  Γöé  065   41   A  Γöé  081   51   Q
  4811.   034   22   "  Γöé  050   32   2  Γöé  066   42   B  Γöé  082   52   R
  4812.   035   23   #  Γöé  051   33   3  Γöé  067   43   C  Γöé  083   53   S
  4813.   036   24   $  Γöé  052   34   4  Γöé  068   44   D  Γöé  084   54   T
  4814.   037   25   %  Γöé  053   35   5  Γöé  069   45   E  Γöé  085   55   U
  4815.   038   26   &  Γöé  054   36   6  Γöé  070   46   F  Γöé  086   56   V
  4816.   039   27   '  Γöé  055   37   7  Γöé  071   47   G  Γöé  087   57   W
  4817.   040   28   (  Γöé  056   38   8  Γöé  072   48   H  Γöé  088   58   X
  4818.   041   29   )  Γöé  057   39   9  Γöé  073   49   I  Γöé  089   59   Y
  4819.   042   2A   *  Γöé  058   3A   :  Γöé  074   4A   J  Γöé  090   5A   Z
  4820.   043   2B   +  Γöé  059   3B   ;  Γöé  075   4B   K  Γöé  091   5B   [
  4821.   044   2C   ,  Γöé  060   3C   <  Γöé  076   4C   L  Γöé  092   5C   \
  4822.   045   2D   -  Γöé  061   3D   =  Γöé  077   4D   M  Γöé  093   5D   ]
  4823.   046   2E   .  Γöé  062   3E   >  Γöé  078   4E   N  Γöé  094   5E   ^
  4824.   047   2F   /  Γöé  063   3F   ?  Γöé  079   4F   O  Γöé  095   5F   _
  4825.  
  4826.                    Lower Case, Miscellaneous
  4827.  
  4828.                  Dec  Hex  Chr Γöé  Dec  Hex  Chr
  4829.                  ---  ---  --- Γöé  ---  ---  ---
  4830.                  096   60   `  Γöé  112   70   p
  4831.                  097   61   a  Γöé  113   71   q
  4832.                  098   62   b  Γöé  114   72   r
  4833.                  099   63   c  Γöé  115   73   s
  4834.                  100   64   d  Γöé  116   74   t
  4835.                  101   65   e  Γöé  117   75   u
  4836.                  102   66   f  Γöé  118   76   v
  4837.                  103   67   g  Γöé  119   77   w
  4838.                  104   68   h  Γöé  120   78   x
  4839.                  105   69   i  Γöé  121   79   y
  4840.                  106   6A   j  Γöé  122   7A   z
  4841.                  107   6B   k  Γöé  123   7B   {
  4842.                  108   6C   l  Γöé  124   7C   |
  4843.                  109   6D   m  Γöé  125   7D   }
  4844.                  110   6E   n  Γöé  126   7E   ~
  4845.                  111   6F   o  Γöé  127   7F   
  4846.  
  4847.                 International; Graphics Characters 1
  4848.  
  4849.   Dec  Hex  Chr Γöé  Dec  Hex  Chr Γöé  Dec  Hex  Chr Γöé  Dec  Hex  Chr
  4850.   ---  ---  --- Γöé  ---  ---  --- Γöé  ---  ---  --- Γöé  ---  ---  ---
  4851.   128   80   ╨É  Γöé  144   90   ╨á  Γöé  160   A0   ╨░  Γöé  176   B0   Γûæ
  4852.   129   81   ╨æ  Γöé  145   91   ╨í  Γöé  161   A1   ╨▒  Γöé  177   B1   ΓûÆ
  4853.   130   82   ╨Æ  Γöé  146   92   ╨ó  Γöé  162   A2   ╨▓  Γöé  178   B2   Γûô
  4854.   131   83   ╨ô  Γöé  147   93   ╨ú  Γöé  163   A3   ╨│  Γöé  179   B3   Γöé
  4855.   132   84   ╨ö  Γöé  148   94   ╨ñ  Γöé  164   A4   ╨┤  Γöé  180   B4   Γöñ
  4856.   133   85   ╨ò  Γöé  149   95   ╨Ñ  Γöé  165   A5   ╨╡  Γöé  181   B5   Γòí
  4857.   134   86   ╨û  Γöé  150   96   ╨ª  Γöé  166   A6   ╨╢  Γöé  182   B6   Γòó
  4858.   135   87   ╨ù  Γöé  151   97   ╨º  Γöé  167   A7   ╨╖  Γöé  183   B7   Γòû
  4859.   136   88   ╨ÿ  Γöé  152   98   ╨¿  Γöé  168   A8   ╨╕  Γöé  184   B8   Γòò
  4860.   137   89   ╨Ö  Γöé  153   99   ╨⌐  Γöé  169   A9   ╨╣  Γöé  185   B9   Γòú
  4861.   138   8A   ╨Ü  Γöé  154   9A   ╨¬  Γöé  170   AA   ╨║  Γöé  186   BA   Γòæ
  4862.   139   8B   ╨¢  Γöé  155   9B   ╨½  Γöé  171   AB   ╨╗  Γöé  187   BB   Γòù
  4863.   140   8C   ╨£  Γöé  156   9C   ╨¼  Γöé  172   AC   ╨╝  Γöé  188   BC   Γò¥
  4864.   141   8D   ╨¥  Γöé  157   9D   ╨¡  Γöé  173   AD   ╨╜  Γöé  189   BD   Γò£
  4865.   142   8E   ╨₧  Γöé  158   9E   ╨«  Γöé  174   AE   ╨╛  Γöé  190   BE   Γò¢
  4866.   143   8F   ╨ƒ  Γöé  159   9F   ╨»  Γöé  175   AF   ╨┐  Γöé  191   BF   ΓöÉ
  4867.  
  4868.                   Graphics Characters 2; Symbols
  4869.  
  4870.   Dec  Hex  Chr Γöé  Dec  Hex  Chr Γöé  Dec  Hex  Chr Γöé  Dec  Hex  Chr
  4871.   ---  ---  --- Γöé  ---  ---  --- Γöé  ---  ---  --- Γöé  ---  ---  ---
  4872.   192   C0   Γöö  Γöé  208   D0   Γò¿  Γöé  224   E0   ╤Ç  Γöé  240   F0   ╨ü
  4873.   193   C1   Γö┤  Γöé  209   D1   Γòñ  Γöé  225   E1   ╤ü  Γöé  241   F1   ╤æ
  4874.   194   C2   Γö¼  Γöé  210   D2   ΓòÑ  Γöé  226   E2   ╤é  Γöé  242   F2   ╨ä
  4875.   195   C3   Γö£  Γöé  211   D3   ΓòÖ  Γöé  227   E3   ╤â  Γöé  243   F3   ╤ö
  4876.   196   C4   ΓöÇ  Γöé  212   D4   Γòÿ  Γöé  228   E4   ╤ä  Γöé  244   F4   ╨ç
  4877.   197   C5   Γö╝  Γöé  213   D5   ΓòÆ  Γöé  229   E5   ╤à  Γöé  245   F5   ╤ù
  4878.   198   C6   Γò₧  Γöé  214   D6   Γòô  Γöé  230   E6   ╤å  Γöé  246   F6   ╨Ä
  4879.   199   C7   Γòƒ  Γöé  215   D7   Γò½  Γöé  231   E7   ╤ç  Γöé  247   F7   ╤₧
  4880.   200   C8   ΓòÜ  Γöé  216   D8   Γò¬  Γöé  232   E8   ╤ê  Γöé  248   F8   ┬░
  4881.   201   C9   Γòö  Γöé  217   D9   Γöÿ  Γöé  233   E9   ╤ë  Γöé  249   F9   ΓêÖ
  4882.   202   CA   Γò⌐  Γöé  218   DA   Γöî  Γöé  234   EA   ╤è  Γöé  250   FA   ┬╖
  4883.   203   CB   Γòª  Γöé  219   DB   Γûê  Γöé  235   EB   ╤ï  Γöé  251   FB   ΓêÜ
  4884.   204   CC   Γòá  Γöé  220   DC   Γûä  Γöé  236   EC   ╤î  Γöé  252   FC   Γäû
  4885.   205   CD   ΓòÉ  Γöé  221   DD   Γûî  Γöé  237   ED   ╤ì  Γöé  253   FD   ┬ñ
  4886.   206   CE   Γò¼  Γöé  222   DE   ΓûÉ  Γöé  238   EE   ╤Ä  Γöé  254   FE   Γûá
  4887.   207   CF   Γòº  Γöé  223   DF   ΓûÇ  Γöé  239   EF   ╤Å  Γöé  255   FF
  4888.  
  4889.  
  4890. ΓòÉΓòÉΓòÉ 4.2. ANSI reference ΓòÉΓòÉΓòÉ
  4891.  
  4892. This section is a quick-reference to commonly-used ANSI commands.  This 
  4893. information is generally applicable to OS/2 and the DOS ANSI drivers. 
  4894.  
  4895. An ANSI command string consists of three parts: 
  4896.  
  4897.     ESC[            The ASCII character ESC, followed by a left bracket. These 
  4898.                     two characters must be present in all ANSI strings. 
  4899.     parameters      Optional parameters for the command.  If there are multiple 
  4900.                     parameters they are separated by semicolons (;). 
  4901.     cmd             A single-letter command.  The case of the letter IS 
  4902.                     meaningful. 
  4903.  
  4904.  For example, to position the cursor to row 7, column 12 the ANSI command is: 
  4905.  
  4906.       ESC[7;12H
  4907.  
  4908.  To transmit ANSI commands to the screen with 4OS2, you should use the ECHO 
  4909.  command.  The ESC character can be generated by inserting it into the string 
  4910.  directly (if you are putting the string in a batch file and your editor will 
  4911.  insert such a character), or by using the internal "escape" character (the 
  4912.  4OS2 default escape character is the caret ^) followed by a lower-case "e". 
  4913.  
  4914.  You can also include ANSI commands in your prompt, using $e to transmit the 
  4915.  ESC character.  You can NOT use PROMPT to transmit ANSI commands to the screen 
  4916.  from a batch file. 
  4917.  
  4918.  Commands 
  4919.  
  4920.     ESC[rowsA               Cursor up 
  4921.     ESC[rowsB               Cursor down 
  4922.     ESC[colsC               Cursor right 
  4923.     ESC[colsD               Cursor left 
  4924.     ESC[row;colH            Set cursor position (top left is row 1, column 1) 
  4925.     ESC[2J                  Clear screen 
  4926.     ESC[K                   Clear from cursor to end of line 
  4927.     ESC[row;colf            Set cursor position, same as "H" command 
  4928.     ESC[=modeh              Set display mode; see table of mode values below 
  4929.     ESC[=model              Set display mode; see table of mode values below 
  4930.     ESC[attr;attr;...m      Set display attributes; see table of attribute 
  4931.                             values below 
  4932.     ESC[key;string;...p     Substitute "string" for the specified key; see key 
  4933.                             substitutions section below 
  4934.     ESC[s                   Save cursor position (may not be nested) 
  4935.     ESC[u                   Restore cursor position after a save 
  4936.  
  4937.  Display Attributes 
  4938.  
  4939.     0         All attributes off (normal white on black) 
  4940.     1         High intensity (bold) 
  4941.     2         Normal intensity 
  4942.     4         Underline (usually effective only on monochrome displays) 
  4943.     5         Blinking 
  4944.     7         Reverse Video 
  4945.     8         Invisible 
  4946.     30-37     Set the foreground color: 
  4947.                 30=Black   31=Red    32=Green  33=Yellow 
  4948.                 34=Blue    35=Magenta  36=Cyan   37=White 
  4949.     40-47     Set the background color, same values as above but substitute 40 
  4950.               for 30 etc. 
  4951.  
  4952.  Settings are cumulative, so (for example) to set a bright red foreground, 
  4953.  first set all attributes off, then set red, then bold: 
  4954.  
  4955.       echo ^e[0;31;1m
  4956.  
  4957.  Display Modes 
  4958.  
  4959.     0       Text 40x25 monochrome 
  4960.     1       Text 40x25 color 
  4961.     2       Text 80x25 monochrome 
  4962.     3       Text 80x25 color 
  4963.     4       Graphics 320x200 4-color 
  4964.     5       Graphics 320x200 4-color 
  4965.     6       Graphics 640x200 2-color 
  4966.     7       (cursor wrap kludge) 
  4967.  
  4968.  Mode 7 is an unfortunate kludge; Setting mode 7 with an "h" command tells ANSI 
  4969.  to wrap text to the next line when it passes the end of a line; setting mode 7 
  4970.  with an "l" (lower-case L) command tells ANSI not to wrap text.  For all other 
  4971.  modes the "h" and "l" commands are equivalent. 
  4972.  
  4973.  Key Substitutions 
  4974.  
  4975.  The key substitutions ("p") command causes ANSI to substitute the text in 
  4976.  "string" when the specified key is pressed.  The key code can be a single 
  4977.  character in quotes, a numeric ASCII value, or an extended code for a non 
  4978.  ASCII key (e.g. function or cursor keys) in the form 0;n, where n is the scan 
  4979.  code for the key. 
  4980.  
  4981.  The string to be substituted can be a single character or character string in 
  4982.  quotes, a numeric ASCII value, or an extended key code. 
  4983.  
  4984.  For a list of numeric ASCII values, see ASCII. 
  4985.  
  4986.  To clear a key substitution, "substitute" the original key for itself (see 
  4987.  examples). 
  4988.  
  4989.  Examples 
  4990.  
  4991.  Clear the display attributes, then set the display to bright cyan on blue, and 
  4992.  clear the screen: 
  4993.  
  4994.       echo ^e[0;44;36;1m^e[2J
  4995.  
  4996.  Substitute "dir"<cr> for F4: 
  4997.  
  4998.       echo ^e[0;62;"dir";13p
  4999.  
  5000.  Undo the above substitution: 
  5001.  
  5002.       echo ^e[0;62;0;62p
  5003.  
  5004.  Set up a prompt that saves the cursor position, displays the 4OS2 shell level, 
  5005.  date, and time on the top line in bright white on magenta, and then restores 
  5006.  the cursor position and sets the color to bright cyan on blue, and displays 
  5007.  the standard prompt: 
  5008.  
  5009.       prompt $e[s$e[1;1f$e[0;45;37;1m$e[K($z)   $d   $t$e[u$e[0;44;36;1m$p$g
  5010.  
  5011.  
  5012. ΓòÉΓòÉΓòÉ 4.3. Extended Key Codes ΓòÉΓòÉΓòÉ
  5013.  
  5014. Key Names 
  5015.  
  5016. The format for a key name in a 4OS2 command or directive is:  [Prefix-]Keyname. 
  5017. The prefix and key name must be separated by a dash.  The prefix can be left 
  5018. out, or it can be any of the following: 
  5019.  
  5020.     Alt     followed by A - Z, 0 - 9, F1 - F12, or Bksp
  5021.     Ctrl    followed by A - Z, F1 - F12, Bksp, Enter,
  5022.               Left, Right, Home, End, PgUp, PgDn, Ins, or Del
  5023.     Shift   followed by F1 - F12 or Tab
  5024.  
  5025. The possible key names are: 
  5026.  
  5027.     A - Z       Esc         Up          PgUp
  5028.     0 - 9       Bksp        Down        PgDn
  5029.     F1 - F12    Tab         Left        Home
  5030.     Ins         Enter       Right       End
  5031.     Del
  5032.  
  5033. The following table lists the common extended key codes used by INKEY: 
  5034.  
  5035.     F1  @59   Alt-F1  @104   Ctrl-F1  @94    Shift-F1  @84
  5036.     F2  @60   Alt-F2  @105   Ctrl-F2  @95    Shift-F2  @85
  5037.     F3  @61   Alt-F3  @106   Ctrl-F3  @96    Shift-F3  @86
  5038.     F4  @62   Alt-F4  @107   Ctrl-F4  @97    Shift-F4  @87
  5039.     F5  @63   Alt-F5  @108   Ctrl-F5  @98    Shift-F5  @88
  5040.     F6  @64   Alt-F6  @109   Ctrl-F6  @99    Shift-F6  @89
  5041.     F7  @65   Alt-F7  @110   Ctrl-F7  @100   Shift-F7  @90
  5042.     F8  @66   Alt-F8  @111   Ctrl-F8  @101   Shift-F8  @91
  5043.     F9  @67   Alt-F9  @112   Ctrl-F9  @102   Shift-F9  @92
  5044.     F10 @68   Alt-F10 @113   Ctrl-F10 @103   Shift-F10 @93
  5045.  
  5046.     Home  @71     Up    @72     PgUp   @73
  5047.     Left  @75                   Right  @77
  5048.     End   @79     Down  @80     PgDn   @81
  5049.     Ins   @82     Del   @83
  5050.  
  5051.     Ctrl-Home  @119     Ctrl-PgUp   @132
  5052.     Ctrl-Left  @115     Ctrl-Right  @116
  5053.     Ctrl-End   @117     Ctrl-PgDn   @118
  5054.  
  5055.     Ctrl-A  1    Ctrl-N  14
  5056.     Ctrl-B  2    Ctrl-O  15
  5057.     Ctrl-C  3    Ctrl-P  16
  5058.     Ctrl-D  4    Ctrl-Q  17
  5059.     Ctrl-E  5    Ctrl-R  18
  5060.     Ctrl-F  6    Ctrl-S  19
  5061.     Ctrl-G  7    Ctrl-T  20
  5062.     Ctrl-H  8    Ctrl-U  21
  5063.     Ctrl-I  9    Ctrl-V  22
  5064.     Ctrl-J  10   Ctrl-W  23
  5065.     Ctrl-K  11   Ctrl-X  24
  5066.     Ctrl-L  12   Ctrl-Y  25
  5067.     Ctrl-M  13   Ctrl-Z  26
  5068.  
  5069.     Alt-A  @30   Alt-N  @49   Alt-1  @120
  5070.     Alt-B  @48   Alt-O  @24   Alt-2  @121
  5071.     Alt-C  @46   Alt-P  @25   Alt-3  @122
  5072.     Alt-D  @32   Alt-Q  @16   Alt-4  @123
  5073.     Alt-E  @18   Alt-R  @19   Alt-5  @124
  5074.     Alt-F  @33   Alt-S  @31   Alt-6  @125
  5075.     Alt-G  @34   Alt-T  @20   Alt-7  @126
  5076.     Alt-H  @35   Alt-U  @22   Alt-8  @127
  5077.     Alt-I  @23   Alt-V  @47   Alt-9  @128
  5078.     Alt-J  @36   Alt-W  @17   Alt-0  @129
  5079.     Alt-K  @37   Alt-X  @45
  5080.     Alt-L  @38   Alt-Y  @21
  5081.     Alt-M  @50   Alt-Z  @44
  5082.