home *** CD-ROM | disk | FTP | other *** search
/ CD Actual 14 / CDACTUAL.iso / cdactual / demobin / share / program / Basic / VWEZ60.ZIP / WIND_REZ.DOC < prev   
Encoding:
Text File  |  1992-11-11  |  287.0 KB  |  7,855 lines

  1.  
  2.  
  3.  
  4.  
  5.  
  6.  
  7.  
  8.  
  9.  
  10.  
  11.  
  12.  
  13.  
  14.  
  15.  
  16.  
  17.  
  18.  
  19.  
  20.  
  21.  
  22.  
  23.  
  24.  
  25.                                 WINDOWS R-E-Z
  26.                                 VER. 6.00
  27.  
  28.  
  29.                                 CONNECT Software
  30.                                 6192 Fawn Meadow
  31.                                 Farmington, NY   14425
  32.  
  33.                                 Richard Magnanti
  34.                                 (716) 924-3439
  35.  
  36.                                 CPS:    71020,2040
  37.                                 GENIE:  R.MAGNANTI
  38.                                 DELPHI: MAGNANTI
  39.  
  40.  
  41.  
  42.  
  43.  
  44.  
  45.  
  46.  
  47.  
  48.  
  49.                                COPYRIGHT (c) 1988 - 1992 BY:
  50.                                CONNECT Software
  51.                                ALL RIGHTS RESERVED
  52.  
  53.  
  54.  
  55.  
  56.  
  57.  
  58.  
  59.  
  60.  
  61.  
  62.  
  63.  
  64.  
  65.  
  66.  
  67.  
  68.  
  69.  
  70.  
  71.  
  72.  
  73.                                     CONTENTS
  74.  
  75.           Differences in versions of WINDOWS R-E-Z ----------------- 1
  76.  
  77.           Important notes for BASIC 7.1 and VB 1.0 for DOS users-- 2-3
  78.  
  79.           General overview ( list of procedures included ) ------- 4-8
  80.  
  81.           System and programming requirements ---------------------- 9
  82.  
  83.           Getting started ----------------------------------------- 10
  84.  
  85.           Windowing routines ----------------------------------- 11-21
  86.                    The Active Window ------------------------------ 11
  87.              1.00  SETWIND ------------------------------------- 11-12
  88.              1.01  MAKEWIND ------------------------------------ 12-14
  89.              1.02  CHNGWIND --------------------------------------- 15
  90.              1.03  PRINTW ----------------------------------------- 15
  91.              1.04  PRINTWHOT ----------------------------------- 15-16
  92.              1.05  SAVEWIND --------------------------------------- 16
  93.              1.06  RESAVE -------------------------------------- 16-17
  94.              1.07  RSTRWIND --------------------------------------- 17
  95.              1.08  DELWIND ------------------------------------- 17-18
  96.              1.09  CLRWIND ---------------------------------------- 18
  97.              1.10  NEWCOLOR --------------------------------------- 18
  98.              1.11  LINEW --------------------------------------- 18-19
  99.              1.12  BOXW ------------------------------------------- 19
  100.              1.13  WAVAIL% ---------------------------------------- 20
  101.              1.14  WINDSTATUS ------------------------------------- 21
  102.  
  103.           Pulldown windows ------------------------------------- 22-30
  104.              2.00  SETPULL ------------------------------------- 22-24
  105.                    Example: SETPULL ---------------------------- 24-25
  106.              2.01  PULLDOWN ------------------------------------ 25-29
  107.              2.02  RSTRPULL ------------------------------------ 29-30
  108.              2.03  CHNGPULL --------------------------------------- 30
  109.  
  110.           Scroll windows --------------------------------------- 31-51
  111.              3.00  SCRLWIND ------------------------------------ 31-40
  112.                    SCRLWIND example ( Auto-exit ) -------------- 40-41
  113.              3.01  B4SCRL -------------------------------------- 41-50
  114.              3.02  MARKED% ------------------------------------- 50-51
  115.  
  116.           Input routines --------------------------------------- 52-79
  117.              4.00  INPTINIT ------------------------------------ 52-53
  118.              4.10  B4INPT -------------------------------------- 53-55
  119.              4.02  INPTWIND ------------------------------------ 55-59
  120.              4.03  RSTRINPT ------------------------------------ 59-60
  121.                    Example: INPTWIND ------------------------------ 61
  122.                    Multi-field Input Overview --------------------- 62
  123.              4.04  SETINPT ---------------------------------------- 63
  124.              4.05  MAKEFIELD ----------------------------------- 64-67
  125.  
  126.  
  127.  
  128.  
  129.  
  130.  
  131.  
  132.  
  133.  
  134.  
  135.  
  136.  
  137.  
  138.  
  139.              4.06  MULTINPT ------------------------------------ 67-72
  140.                    Editing features for input routines ------------ 73
  141.              4.07  UPDATEFIELD ------------------------------------ 74
  142.              4.08  GETANS -------------------------------------- 74-76
  143.              4.09  CHOICEWIND% --------------------------------- 76-78
  144.              4.10  CHOICEBAR% ---------------------------------- 78-79
  145.  
  146.           Directory routines ----------------------------------- 80-85
  147.              5.00  GETDISK ---------------------------------------- 80
  148.              5.01  FINDPATH --------------------------------------- 80
  149.              5.02  SETDISK ---------------------------------------- 80
  150.              5.03  DISKSIZE --------------------------------------- 81
  151.              5.04  FINDDIR ------------------------------------- 81-83
  152.                    A directory scroll window ( example ) ------- 84-85
  153.  
  154.           Keyboard and Mouse routines -------------------------- 86-91
  155.              6.00  GETAKEY%  -------------------------------------- 86
  156.                    GETAKEY% example ------------------------------- 86
  157.              6.01  CLEARKB ---------------------------------------- 87
  158.              6.02  MOUSEON ---------------------------------------- 87
  159.              6.03  MOUSEHIDE -------------------------------------- 87
  160.              6.04  MOUSESHOW ----------------------------------- 87-88
  161.              6.05  MOUSEROW% -------------------------------------- 88
  162.              6.06  MOUSECOL% -------------------------------------- 88
  163.              6.07  MOUSEPOS --------------------------------------- 88
  164.              6.08  MOUSELIMIT ------------------------------------- 88
  165.              6.09  LBUTTON% --------------------------------------- 88
  166.              6.10  RBUTTON% --------------------------------------- 89
  167.              6.11  MOUSEINWIND% ----------------------------------- 89
  168.              6.12  MOUSEINMULT% -------------------------------- 90-91
  169.  
  170.           Information line routines ---------------------------- 91-95
  171.              8.00 INFOLINE ---------------------------------------- 91
  172.              8.01 PRINTINFO ------------------------------------ 91-92
  173.              8.02 INFOFIXED --------------------------------------- 92
  174.              8.03 RSTRINFO ---------------------------------------- 92
  175.                    Examples: Info-line routines ---------------- 93-95
  176.  
  177.           Misc Routines ---------------------------------------- 96-97
  178.              7.00  DOSOUND ---------------------------------------- 96
  179.              7.01  DISPLAYROWS% ----------------------------------- 96
  180.              7.02  PEEKASM& --------------------------------------- 96
  181.              7.03  GETCUR& ---------------------------------------- 96
  182.              7.04  SETCUR& ---------------------------------------- 97
  183.              7.05  CUROFF ----------------------------------------- 97
  184.  
  185.           Program format -------------------------------------- 98-101
  186.  
  187.           Event Trapping ----------------------------------------- 102
  188.  
  189.           Description of files ------------------------------- 103-105
  190.  
  191.  
  192.  
  193.  
  194.  
  195.  
  196.  
  197.  
  198.  
  199.  
  200.  
  201.  
  202.  
  203.  
  204.  
  205.           Errors --------------------------------------------- 106-110
  206.  
  207.           Appendix ------------------------------------------- 111-114
  208.              Color attribute chart ------------------------------- 111
  209.              Multi-field code chart ------------------------------ 112
  210.              Border designation chart ---------------------------- 113
  211.              GETAKEY code values --------------------------------- 114
  212.  
  213.           Restrictions and disclaimer ---------------------------- 115
  214.  
  215.  
  216.  
  217.  
  218.  
  219.  
  220.  
  221.  
  222.  
  223.  
  224.  
  225.  
  226.  
  227.  
  228.  
  229.  
  230.  
  231.  
  232.  
  233.  
  234.  
  235.  
  236.  
  237.  
  238.  
  239.  
  240.  
  241.  
  242.  
  243.  
  244.  
  245.  
  246.  
  247.  
  248.  
  249.  
  250.  
  251.  
  252.  
  253.  
  254.  
  255.  
  256.  
  257.  
  258.  
  259.  
  260.  
  261.  
  262.  
  263.  
  264.  
  265.  
  266.  
  267.  
  268.  
  269.  
  270.  
  271.                             ***************************
  272.                             *  NOTE ------ READ THIS! *
  273.                             ***************************
  274.  
  275.               The information in this documentation refers to the
  276.           enhanced version of WINDOWS R-E-Z.  Differences between the
  277.           QuickBasic 4.50, BASIC 7.1 (PDS) and Visual Basic for DOS
  278.           (VBDOS) versions are detailed.  The documentation can be used
  279.           for the unenhanced versions with the following exceptions.
  280.  
  281.  
  282.               1. MEMORY - Additional libraries are included in the
  283.           enhanced versions which do not contain error checking or
  284.           window status capability.  These libraries can be used after
  285.           the program is de-bugged and represent an opportunity for
  286.           considerable memory reduction.
  287.  
  288.                         - Additional libraries are included in the
  289.           enhanced versions which can be used for programs not requiring
  290.           event handling.  The libraries in the unenhanced versions allow
  291.           event handling.  Extra libraries for programs not requiring
  292.           event handling are not included in the unenhanced versions.
  293.           Modules compiled from the QB/QBX/VBDOS environment will use the
  294.           event handing switches ( /W or /V ) in the unenhanced versions
  295.           even if event handling is not used.  This produces larger and
  296.           slower programs.
  297.  
  298.  
  299.               2. The BASIC 7.1 and VBDOS unenhanced versions do not
  300.           allow the use of unnamed ( blank ) COMMON blocks.  The
  301.           enhanced version has provisions for the use of same.
  302.  
  303.  
  304.  
  305.  
  306.  
  307.  
  308.  
  309.  
  310.  
  311.  
  312.  
  313.  
  314.  
  315.  
  316.  
  317.           **********************************************************
  318.           **  For information on obtaining the enhanced version   **
  319.           **  of WINDOWS R-E-Z see the file ORDER.ME.             **
  320.           **********************************************************
  321.  
  322.  
  323.  
  324.  
  325.  
  326.                                        1
  327.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  328.  
  329.  
  330.  
  331.  
  332.  
  333.  
  334.  
  335.  
  336.  
  337.              Important notes for BASIC 7.1 and VBDOS 1.00 users.
  338.  
  339.  
  340.           ENHANCED AND UNENHANCED VERSIONS:
  341.  
  342.           The /Ea option may be used when loading QBX or VBDOS.
  343.           This allows the use of expanded memory.
  344.  
  345.           Window memory resides in a separate segment of string space
  346.           reserved for strings placed in unnamed ( blank ) COMMON
  347.           blocks.  DO NOT USE BLANK COMMON BLOCKS IN YOUR PROGRAM.
  348.  
  349.           EXAMPLE: COMMON SHARED A$                ' NOT PERMITTED
  350.                    COMMON SHARED /BLOCKNAME/ A$    ' PERMITTED
  351.  
  352.  
  353.           Maximum window memory is 64k bytes.  Calls to MAKEWIND or
  354.           SAVEWIND requesting window memory in excess of 64k bytes
  355.           will result in an "Out of string space" error message.  As
  356.           64k represents sixteen full display windows (80 x 25 mode)
  357.           this limitation should not be restrictive.
  358.  
  359.  
  360.           The use of far strings is required.  This is the default for
  361.           programs compiled from the QBX environment   If the source
  362.           code is compiled on the command line the /Fs option must be
  363.           used with BC.  Unlike BASIC 7.1, VBDOS always uses far
  364.           strings.
  365.  
  366.  
  367.           ENHANCED VERSION ONLY:
  368.  
  369.           Additional object files PDSALT.OBJ or VBALT.OBJ are included
  370.           which allow the use of unnamed (blank) COMMON blocks.  They
  371.           must replace the object file PDSVBMEM.OBJ, which is included
  372.           in the BASIC 7.1 and VB for DOS libraries.  Window memory will
  373.           share main module string space after this change is made.  To
  374.           make this change;
  375.  
  376.           1. Make new library files. ( Back-up old library files first! )
  377.  
  378.           LIB PDSALL.LIB-PDSVBMEM.OBJ+PDSALT.OBJ;    ( BASIC 7.1 )
  379.           LIB PDSNER.LIB-PDSVBMEM.OBJ+PDSALT.OBJ;    ( BASIC 7.1 )
  380.           LIB PDSTRAP.LIB-PDSVBMEM.OBJ+PDSALT.OBJ;   ( BASIC 7.1 )
  381.           LIB PDSNETRP.LIB-PDSVBMEM.OBJ+PDSALT.OBJ;  ( BASIC 7.1 )
  382.  
  383.  
  384.           LIB VBALL.LIB-PDSVBMEM.OBJ+VBALT.OBJ;      ( VBDOS )
  385.           LIB VBNER.LIB-PDSVBMEM.OBJ+VBALT.OBJ;      ( VBDOS )
  386.           LIB VBTRAP.LIB-PDSVBMEM.OBJ+VBALT.OBJ;     ( VBDOS )
  387.           LIB VBNETRP.LIB-PDSVBMEM.OBJ+VBALT.OBJ;    ( VBDOS )
  388.  
  389.  
  390.  
  391.  
  392.                                        2
  393.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  394.  
  395.  
  396.  
  397.  
  398.  
  399.  
  400.  
  401.  
  402.  
  403.           2. Make new quick-libraries. ( Back-up old quick-libraries! )
  404.  
  405.           LINK/Q PDSALL.LIB,PDSALL.QLB,,QBXQLB.LIB;     ( BASIC 7.1 )
  406.           LINK/Q PDSNER.LIB,PDSNER.QLB,,QBXQLB.LIB;     ( BASIC 7.1 )
  407.           LINK/Q PDSTRAP.LIB,PDSTRAP.QLB,,QBXQLB.LIB;   ( BASIC 7.1 )
  408.           LINK/Q PDSNETRP.LIB,PDSNETRP.QLB,,QBXQLB.LIB; ( BASIC 7.1 )
  409.  
  410.           LINK/Q VBALL.LIB,VBALL.QLB,,VBDOSQLB.LIB;     ( VBDOS )
  411.           LINK/Q VBNER.LIB,VBNER,,VBDOSQLB.LIB;         ( VBDOS )
  412.           LINK/Q VBTRAP.LIB,VBTRAP.QLB,,VBDOSQLB.LIB;   ( VBDOS )
  413.           LINK/Q VBNETRP.LIB,VBNETRP,,VBDOSQLB.LIB;     ( VBDOS )
  414.  
  415.  
  416.  
  417.  
  418.  
  419.  
  420.  
  421.  
  422.  
  423.  
  424.  
  425.  
  426.  
  427.  
  428.  
  429.  
  430.  
  431.  
  432.  
  433.  
  434.  
  435.  
  436.  
  437.  
  438.  
  439.  
  440.  
  441.  
  442.  
  443.  
  444.  
  445.  
  446.  
  447.  
  448.  
  449.  
  450.  
  451.  
  452.  
  453.  
  454.  
  455.  
  456.  
  457.  
  458.                                        3
  459.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  460.  
  461.  
  462.  
  463.  
  464.  
  465.  
  466.  
  467.  
  468.  
  469.                             *** GENERAL OVERVIEW ***
  470.  
  471.               WINDOWS R-E-Z is a collection of QuickBASIC and assembly
  472.           routines which provide users of QuickBASIC 4.50,  BASIC 7.1
  473.           ( PDS ), and Visual BASIC for DOS with a complete window
  474.           management system.  With WINDOWS R-E-Z users can make, save,
  475.           restore, and delete up to twenty windows.  The memory used to
  476.           save windowed areas is dynamically allocated and outside of
  477.           basic's normal data storage area leaving more room for the
  478.           basic programs data.  Windows are assigned a number from zero
  479.           to twenty.
  480.  
  481.                INPUT WINDOWS, MULTI-FIELD INPUT SCREENS, CHOICE WINDOWS,
  482.           CHOICE BARS and GET ANSWER WINDOWS all provide an excellent
  483.           source for user input.  Input fields may be alpha/numeric,
  484.           numeric, date or restricted.  Multi-field input fields may be
  485.           use to emulate "buttons".  Additional numerous options are
  486.           included for input fields.
  487.  
  488.               WINDOWS R-E-Z provides users the ability to incorporate
  489.           "PULLDOWN WINDOWS", emulating those used in the QuickBASIC
  490.           programming environment, in their programs.
  491.  
  492.               Directory routines find the default drive and path, disk
  493.           size and free space, and directory listing for any path.
  494.           File size, date, time, and attributes can also be found.
  495.  
  496.               Information line routines provide an easy means to print
  497.           messages, directions, or prompts, anyplace on the display.
  498.  
  499.               SCROLL WINDOWS may be used to scroll through small lists
  500.           or large databases.
  501.  
  502.               Also includes are numerous KEYBOARD and MOUSE routines.
  503.  
  504.               All of the routines require a minimal amount of initial-
  505.           ization and the resulting programs present a professional
  506.           appearance.
  507.  
  508.               Unlike many other basic "add-ons", WINDOWS R-E-Z
  509.           provides extensive error detection and reporting.
  510.  
  511.           Procedures included:
  512.  
  513.             SETWIND -------- Set up routine for windowing procedures.
  514.  
  515.             MAKEWIND ------- Makes a window.  Saves windowed area to
  516.                              window memory.  The window becomes the
  517.                              "active window".
  518.  
  519.             SAVEWIND ------- Saves a screen area to window memory.
  520.  
  521.  
  522.  
  523.  
  524.                                        4
  525.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  526.  
  527.  
  528.  
  529.  
  530.  
  531.  
  532.  
  533.  
  534.  
  535.             RESAVE --------- Saves the active window.
  536.  
  537.             RSTRWIND ------- Restores a window area to the display.
  538.  
  539.             DELWIND -------- Deletes a window area from window memory.
  540.  
  541.             CHNGWIND ------- Changes the active window to another
  542.                              window.
  543.  
  544.             NEWCOLOR ------- Changes the print-to color of the active
  545.                              window for text printed by PRINTW.
  546.                              The print-to color is used by CLRWIND to
  547.                              clear the active window's interior.
  548.  
  549.             CLRWIND -------- Clears the interior of the active window.
  550.  
  551.             PRINTW --------- Prints text in the active window using
  552.                              the window's "print-to" color.
  553.  
  554.             PRINTWHOT ------ Prints text in the active window. One
  555.                              character is printed in a different color.
  556.  
  557.             LINEW ---------- Prints a line in the active window using
  558.                              the window's "print-to" color.
  559.  
  560.             BOXW ----------- Prints a box in the active window using
  561.                              the window's "print-to" color.
  562.  
  563.             WAVAIL% -------- (FUNCTION) Reports a window's availability.
  564.  
  565.             WINDSTATUS ----- Reports window memory status.
  566.  
  567.             B4SCRL --------- Sets exit keys, "marked entry string"
  568.                              scroll bar status, tag character color,
  569.                              and refresh status for a subsequent call
  570.                              to SCRLWIND.
  571.  
  572.  
  573.             SCRLWIND ------- Places a scrollable list in the active
  574.                              window.
  575.  
  576.             MARKED% -------- (FUNCTION) Returns position of marked
  577.                              items after a call to SCRLWIND.
  578.  
  579.             SETPULL -------- Set up routine for pulldown windows.
  580.  
  581.             PULLDOWN ------- Makes pulldown windows.  On exit the
  582.                              displayed pulldown window is the active
  583.                              pulldown window.
  584.  
  585.  
  586.  
  587.  
  588.  
  589.  
  590.                                        5
  591.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  592.  
  593.  
  594.  
  595.  
  596.  
  597.  
  598.  
  599.  
  600.  
  601.             RSTRPULL ------- Restores the area under the active
  602.                              pulldown window and menubar.  Deactivates
  603.                              the active pulldown window.
  604.  
  605.             CHNGPULL ------- Changes the color of, and disables or
  606.                              enables an item in a pulldown window.
  607.  
  608.             INPTINIT ------- Initializes input memory. Sets date format,
  609.                              decimal designator, and "exit keys".
  610.  
  611.             INPTWIND ------- Makes an input field with an optional
  612.                              window.  The field can be edited by
  613.                              the user.  On exit the displayed input
  614.                              line or window is the active input window.
  615.  
  616.  
  617.             RSTRINPT ------- Restores the area under the active input
  618.                              window to the display.  Deactivates the
  619.                              active input window.
  620.  
  621.             SETINPT -------- Set up routine for multi-field input
  622.                              screens.
  623.  
  624.             MAKEFIELD ------ Makes an input field or button for routine
  625.                              MULTINPT
  626.  
  627.             MULTINPT ------- Places input fields on the screen as
  628.                              defined by a previous calls to SETINPT and
  629.                              MAKEFIELD.
  630.  
  631.             UPDATEFIELD ---- Updates a field in a multi-field input screen.
  632.  
  633.             CHOICEWIND%  --- Makes a text window with one to ten user
  634.                              choices.  Returns the selected choice.
  635.  
  636.             CHOICEBAR%   --- Presents the user with 1 to 10 choices.
  637.                              Returns the selected choice.
  638.  
  639.             GETANS --------- Makes a get answer window or single line
  640.                              prompt.  Waits for a single key response.
  641.  
  642.             INFOLINE ------- Sets coordinates and color for the info-line.
  643.                              Also turns on the info-line.  Saves the area
  644.                              of the display reserved by the info-line. The
  645.                              info-line displays a prompt or message.
  646.  
  647.             PRINTINFO ------ Prints a prompt or message in the info-line.
  648.  
  649.  
  650.  
  651.  
  652.  
  653.  
  654.  
  655.  
  656.                                        6
  657.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  658.  
  659.  
  660.  
  661.  
  662.  
  663.  
  664.  
  665.  
  666.  
  667.             INFOFIXED ------ Defines a fixed string for the info-line. The
  668.                              string is printed every time PRINTINFO is
  669.                              called.  The string specified in PRINTINFO is
  670.                              added to the string defined in this routine.
  671.                              Useful for scroll and pulldown windows.
  672.  
  673.             RSTRINFO ------- Restores the display area under, and option-
  674.                              ally turns off the info-line.
  675.             DOSOUND -------- Produces sound determined by SETWIND.
  676.  
  677.             GETDISK -------- Returns the default disk drive.
  678.  
  679.             SETDISK -------- Sets the default disk drive.
  680.  
  681.             FINDPATH ------- Returns the default path for any drive
  682.                              ( current directory ).
  683.             DISKSIZE ------- Returns disk size and free space.
  684.  
  685.             FINDDIR -------- Returns the directory of any drive or path
  686.                              in a string array.
  687.  
  688.             GETAKEY% ------- Returns a code for a key pressed or
  689.                              zero if no key is pressed.
  690.  
  691.             MOUSEON% -------- Turns the mouse on or off.
  692.  
  693.             MOUSESHOW ------ Displays the mouse cursor.
  694.  
  695.             MOUSEHIDE ------ Hides the mouse cursor.
  696.  
  697.             MOUSEROW% ------ Returns the row position of the mouse
  698.                              cursor.
  699.  
  700.             MOUSECOL% ------ Returns the column position of the mouse
  701.                              cursor.
  702.  
  703.             MOUSEPOS ------- Positions the mouse cursor at any screen
  704.                              location.
  705.  
  706.             MOUSELIMIT ----- Limits mouse movement to a defined area
  707.                              of the display.
  708.  
  709.             LBUTTON% ------- Returns the left mouse button status.
  710.  
  711.             RBUTTON% ------- Returns the right mouse button status.
  712.  
  713.             MOUSEINWIND% --- Returns a value signifying if the mouse
  714.                              cursor is in a specified window.
  715.  
  716.             MOUSEINMULT% --- Returns the field number the mouse cursor
  717.                              occupies for a specified multi-field
  718.                              input screen.
  719.  
  720.  
  721.  
  722.                                        7
  723.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  724.  
  725.  
  726.  
  727.  
  728.  
  729.  
  730.  
  731.  
  732.  
  733.             DISPLAYROW% ---- Returns the number of display rows for
  734.                              the active screen.
  735.  
  736.             PEEKASM& ------- Returns a 1,2,3 or 4 byte value for a
  737.                              specified memory location.
  738.  
  739.  
  740.             GETCUR& --------- Returns the cursor position and size in a
  741.                               long integer.
  742.  
  743.             SETCUR  --------- Restores the cursor position and size.
  744.  
  745.             CUROFF ---------- Turns the system cursor off.
  746.  
  747.  
  748.  
  749.  
  750.  
  751.  
  752.  
  753.  
  754.  
  755.  
  756.  
  757.  
  758.  
  759.  
  760.  
  761.  
  762.  
  763.  
  764.  
  765.  
  766.  
  767.  
  768.  
  769.  
  770.  
  771.  
  772.  
  773.  
  774.  
  775.  
  776.  
  777.  
  778.  
  779.  
  780.  
  781.  
  782.  
  783.  
  784.  
  785.  
  786.  
  787.  
  788.                                        8
  789.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  790.  
  791.  
  792.  
  793.  
  794.  
  795.  
  796.  
  797.  
  798.  
  799.             --------------------------------------------------------
  800.  
  801.                   ***  SYSTEM AND PROGRAMMING REQUIREMENTS ***
  802.  
  803.             COMPUTER:
  804.                IBM PC (XT or AT) or compatible computer.  One disk drive.
  805.  
  806.             VIDEO ADAPTOR CARD:
  807.                MONO, CGA, EGA or VGA emulating CGA.
  808.  
  809.             PROGRAMMING LANGUAGE:
  810.                For the QuickBASIC. version;
  811.  
  812.                    QuickBASIC version 4.5.
  813.                     - Text mode --  80 by 25, 80 by 43, or 80 by 50
  814.  
  815.                For the BASIC 7.1 (PDS) version;
  816.  
  817.                    BASIC 7.1.
  818.                    - Text mode --  80 by 25, 80 by 43, or 80 by 50
  819.  
  820.                    - Requires use of "far strings". This is the default
  821.                      if executable programs are produced from within
  822.                      QBX.  If modules are compiled using BC on the command
  823.                      line ( outside of the QBX environment ) the /Fs option
  824.                      must be used.
  825.  
  826.                For the VISUAL BASIC FOR DOS version;
  827.  
  828.                    Visual BASIC 1.00
  829.                    - Text mode --  80 by 25, 80 by 43, or 80 by 50
  830.  
  831.             DOS: Version 2.1 or higher.
  832.  
  833.             -------------------------------------------------------
  834.  
  835.  
  836.  
  837.  
  838.  
  839.  
  840.  
  841.  
  842.  
  843.  
  844.  
  845.  
  846.  
  847.  
  848.  
  849.  
  850.  
  851.  
  852.  
  853.  
  854.                                        9
  855.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  856.  
  857.  
  858.  
  859.  
  860.  
  861.  
  862.  
  863.  
  864.  
  865.                                GETTING STARTED
  866.  
  867.  
  868.          Before using the routines included in WINDOW R-E-Z, it is
  869.          necessary to set several global values.  The following routines
  870.          set these values.  These routines must be called at the start
  871.          of any program.
  872.  
  873.  
  874.          ROUTINE            USED TO...
  875.  
  876.          SETWIND            1. Set the default sound for all routines
  877.                             2. Set the shadow color for all windows.
  878.                             3. Set "slow print" for CGA adaptors.
  879.                             4. Determine how certain hi-intensity
  880.                                characters are displayed.
  881.                             3. Set the color of button brackets ( < > ).
  882.  
  883.                             SETWIND MUST BE CALLED BEFORE USING ANY OF
  884.                             THE ROUTINES INCLUDED WITH WINDOW R-E-Z.
  885.  
  886.  
  887.          INPTINIT           1. Set the date format for input routines.
  888.                             2. Set the comma designator for input
  889.                                routines.
  890.                             3. Set the cursor "start position" for input
  891.                                routines.
  892.                             4. Determine if the first valid key pressed
  893.                                erases an input field.
  894.                             5. Determine if an invalid key produces a
  895.                                sound while entering data in an input
  896.                                field.
  897.  
  898.                             INPTINIT MUST BE CALL PRIOR TO CALLING
  899.                             ROUTINES MULTINPT, INPTWIND, OR SCRLWIND,
  900.                             CHOICEWIND, OR CHOICEBAR.
  901.  
  902.  
  903.          MOUSEON            1. Initializes the mouse and optionally
  904.                                turns the mouse "ON".
  905.  
  906.                            MOUSEON MUST BE CALLED TO USE THE MOUSE
  907.  
  908.  
  909.          SEE THE DETAILED DESCRIPTIONS FOR THE INDIVIDUAL ROUTINES.
  910.  
  911.  
  912.  
  913.  
  914.  
  915.  
  916.  
  917.  
  918.  
  919.  
  920.                                        10
  921.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  922.  
  923.  
  924.  
  925.  
  926.  
  927.  
  928.  
  929.  
  930.  
  931.                              USING WINDOWS R-E-Z
  932.  
  933.          THE ACTIVE WINDOW
  934.  
  935.          When a window is defined ( made ) the number assigned to it
  936.          by the programmer represents the area covered by the window.
  937.          The area is restored or deleted via it's "number".  Up to 20
  938.          window areas can be saved.  The memory used to save the
  939.          window areas is automatically managed by WINDOWS R-E-Z.
  940.  
  941.          Any time a window is made it becomes the "active" window. The
  942.          active window is used by the following routines.
  943.  
  944.               PRINTW --- Prints text in the active window.
  945.               LINEW ---- Prints a line in the active window.
  946.               BOXW ----- Prints a box in the active window.
  947.               SCRLWIND - Places a scrollable list in the active
  948.                          window.
  949.               CLRWIND -- Clears all text from the interior of the
  950.                          active window.
  951.               RESAVE  -- Saves the active window and any text in the
  952.                          active window.
  953.               NEWCOLOR - Changes the "print-to" color of the active
  954.                          window.
  955.  
  956.          NOTE: ACTIVE INPUT AND PULLDOWN WINDOWS MAY ALSO EXIST. THESE
  957.          WINDOWS ARE NOT RELATED TO THE ACTIVE WINDOW GENERATED BY THE
  958.          WINDOWING ROUTINES.
  959.  
  960.  
  961.          1.00 SETWIND ( FST%, SND%, SHAD%, NOHI%, BRACKETATTR% )
  962.  
  963.               Description:   SETWIND must be called at least once in
  964.               any program using the routines in WINDOWS-R-E-Z, prior
  965.               to calling the routines.  This procedure initializes
  966.               window memory.  It also sets the default windowing
  967.               speed, sound, window shadow color, and "button" bracket
  968.               color.
  969.  
  970.               The first call to SETWIND initializes window memory and
  971.               sets the default parameters.  Subsequent calls to
  972.               SETWIND will not affect window memory but can be used
  973.               to change the default parameters.
  974.  
  975.               NOTE: IF A CLEAR STATEMENT IS EXECUTED BY THE PROGRAM
  976.               ALL WINDOW MEMORY IS LOST.  WINDOW AREAS SAVED IN WINDOW
  977.               MEMORY ARE LOST.  SETWIND MUST BE CALLED AGAIN TO RE-
  978.               INITIALIZE WINDOW MEMORY AFTER EXECUTING A CLEAR STATEMENT.
  979.  
  980.               Arguments:      FST% is used to allow "fast" windowing
  981.               if a CGA video card, or emulation, is detected.  If
  982.               FST% = 0  window routines will be slower on computers
  983.  
  984.  
  985.  
  986.                                        11
  987.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  988.  
  989.  
  990.  
  991.  
  992.  
  993.  
  994.  
  995.  
  996.  
  997.               with CGA.  If FST%  = 1 window routines will be "fast" on
  998.               computers with CGA.  This may, however, cause "snow" with
  999.               certain CGA cards.  If a monochrome, EGA, or VGA card is
  1000.               detected, FST% is ignored.  All windowing is "fast".
  1001.  
  1002.                                SND% determines which sound will be
  1003.               generated by the routines.   If SND% = 1 a "CLICK" sound
  1004.               will be generated.  If SND% = 2 a "BEEP" sound will be
  1005.               produced.  Any other value produces no sound.
  1006.  
  1007.                                SHAD% sets the color for window shad-
  1008.               ows.  See the color attribute chart for details.  Set-
  1009.               ting SHAD% to 7 works well for monochrome displays while
  1010.               setting SHAD% to 8 works well for color displays.
  1011.  
  1012.                                NOHI% determines how pulldown and scroll
  1013.               window routines display "key" characters.  It also
  1014.               determines how the button brackets ( < > ) for the active
  1015.               choice for routines SCRLWIND, INPTWIND, CHOICEBAR, and
  1016.               CHOICEWIND are displayed.  In addition, if a field defined
  1017.               in routine MAKEFIELD is use to make a "button field" the
  1018.               color of characters used as brackets ( when the field is
  1019.               active via routine MULTINPT ) is affected by the value of
  1020.               NOHI%  If NOHI% = 0 key characters or brackets are
  1021.               displayed in their specified color.  If NOHI% = 1 "key"
  1022.               characters and brackets are displayed in reverse video.
  1023.               This is appropriate for LCD displays which can not display
  1024.               high intensity characters.  NOHI% affects "key" characters
  1025.               and "active brackets" ONLY if they have been defined to
  1026.               have a different color then normal characters and inactive
  1027.               brackets.
  1028.  
  1029.                                BRACKETATTR% determines the foreground
  1030.               color of button brackets ( < > ) for active choices or
  1031.               fields in routines SCRLWIND, INPTWIND, CHOICEWIND,
  1032.               CHOICEBAR, and MULTINPT.  It only affects the brackets for
  1033.               the active choice.  BRACKETATTR% may be set from 0 to 15.
  1034.               For most applications BRACKETATTR% can be set to 15 with
  1035.               good results.  If BRACKETATTR% is set to zero the bracket
  1036.               color for the active choice does not change.  The brackets
  1037.               retain their in-active color.
  1038.  
  1039.  
  1040.          1.01 MAKEWIND (W%, LABEL$, TR%, LC%, WIDE%, NR%, ATTR%, BORBER%)
  1041.  
  1042.               Description:   Makes a window.  May also save a window-
  1043.               ed area to window memory.  The window becomes the active
  1044.               window.   Calls to PRINTW, LINEW, SCRLWIND, CLRWIND, BOXW,
  1045.               RESAVE, and NEWCOLOR refer to the active window. If an
  1046.               attempt is made to place a window on the display and it
  1047.               will not fit on the display an error will be reported. The
  1048.  
  1049.  
  1050.  
  1051.  
  1052.                                        12
  1053.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  1054.  
  1055.  
  1056.  
  1057.  
  1058.  
  1059.  
  1060.  
  1061.  
  1062.  
  1063.               maximum size of a window is dependent on the screen mode
  1064.               when a window is made.
  1065.  
  1066.               NOTE: TEXT MODES 80x25, 80x43 AND 80x50 ARE SUPPORTED.
  1067.  
  1068.  
  1069.               Arguments:   W% is the window number and must equal 0 to
  1070.               20.  If W% = 0 the area under the window is not saved.
  1071.               A window is simply made.  If W% is from 1 to 20 the area
  1072.               under the window is saved and may be restored at a later
  1073.               time via a call to RSTRWIND.  If W% is the number of a
  1074.               window area previously saved by MAKEWIND or SAVEWIND an
  1075.               error is reported.
  1076.  
  1077.               NOTE: WHEN WINDOW NUMBER 1 TO 20 IS MADE AN IMAGE OF THE
  1078.               DISPLAY AREA UNDER THE WINDOW IS SAVED IN WINDOW MEMORY.
  1079.               THIS AREA MAY BE RESTORED TO THE DISPLAY BY CALLING
  1080.               ROUTINE RSTRWIND.  ROUTINE RSTRWIND MAY OPTIONALLY REMOVE
  1081.               THE "SAVED" DISPLAY AREA FROM WINDOW MEMORY.
  1082.                     A SECOND ROUTINE, DELWIND, MAY BE USED TO REMOVE
  1083.               THE "SAVED" DISPLAY AREA FROM WINDOW MEMORY.  THIS
  1084.               ROUTINE DOES NOT, HOWEVER, RESTORE THE "SAVED" DISPLAY
  1085.               AREA TO THE SCREEN.  DO NOT CONFUSE THESE ROUTINES!!
  1086.               SEE THE DESCRIPTIONS FOR ROUTINES RSTRWIND AND DELWIND
  1087.               FOR DETAILS.
  1088.  
  1089.                            LABEL$ is the text printed on the top
  1090.               border or in the title box (see BORDER%) of the window.
  1091.               By default the print starts on the second column.  If
  1092.               the first character of LABEL$ ="@" the text will be
  1093.               centered.  If LABEL$ is too long it will be truncated to
  1094.               fit on the top border or in the title box.
  1095.  
  1096.                            TR% is the top row of the window.  If TR% =
  1097.               100 the window will be centered from top to bottom.
  1098.  
  1099.                            LC% is the left column position of the win-
  1100.               dow. If LC% = 100 the window will be centered from left
  1101.               to right.
  1102.  
  1103.                            WIDE% is the window's width.  WIDE% must be
  1104.               greater than 2.  WIDE% + LC% -1 must not be greater than
  1105.               80. ( The displays width ).
  1106.  
  1107.                            NR% is the number of rows in the window and
  1108.               must be greater than 2.  NR% + TR% must not be greater
  1109.               than the display rows + 1 .  If NR% is less than 5 a window
  1110.               title box is not permitted.
  1111.  
  1112.                            ATTR% is the window's color and may be in
  1113.               the range of 0 to 255.  The foreground ( window's label
  1114.               and border ) color equals ATTR% MOD 16.  The background
  1115.  
  1116.  
  1117.  
  1118.                                        13
  1119.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  1120.  
  1121.  
  1122.  
  1123.  
  1124.  
  1125.  
  1126.  
  1127.  
  1128.  
  1129.               color equals INT( ATTR% / 16 ). If the background color
  1130.               is greater than 7 the foreground flashes and the back-
  1131.               ground color equals background color - 8. If the fore-
  1132.               ground and background colors are the same the border and
  1133.               label will not be visible. ( SEE THE COLOR ATTRIBUTE
  1134.               CHART.)  ATTR% becomes the print-to color for window W%.
  1135.  
  1136.                            BORDER% sets the window's border and shadow
  1137.               and can be up to 3 digits in length.
  1138.  
  1139.                            DIGIT    =    #3  #2  #1
  1140.                            Example   =    1   1   1   ( 111 )
  1141.  
  1142.                            Digit #1 sets the border.
  1143.  
  1144.                            0 = No border
  1145.                            1 = Single line border
  1146.                            2 = Double line border
  1147.  
  1148.                            Digit #2 sets the shadow.
  1149.  
  1150.                            0 = No shadow
  1151.                            1 = Right/Bottom shadow
  1152.                            2 = Left/Bottom shadow
  1153.                            3 = Left/Top shadow
  1154.                            4 = Right/top Shadow
  1155.  
  1156.                            Digit #3 set the title box.
  1157.  
  1158.                            0 = No title box
  1159.                            1 = title box
  1160.  
  1161.               The example (111) has a 1 for each digit.  The window
  1162.               will have a single lined border, a shadow on the right
  1163.               and bottom and a title box
  1164.  
  1165.               NOTE:  IF BORDER% IS 100 OR GREATER AND THE NUMBER OF
  1166.               ROWS (NR%) IS LESS THAN 5 TITLE BOXES ARE NOT PERMITTED.
  1167.               SEE THE BORDER DESIGNATION CHART IN THE APPENDIX FOR
  1168.               FURTHER DETAILS.
  1169.  
  1170.          1.02 CHNGWIND (W%)
  1171.  
  1172.               Description:  Makes window, W%, the active window.
  1173.               W% must represent a window area in window memory.
  1174.  
  1175.               Argument:   W% is the window number.  It must range from
  1176.               0 to 20.  If W% does not represent a window saved by a
  1177.               previous call to MAKEWIND, CHNGWIND reports an error.
  1178.  
  1179.               NOTE:  W% CAN NOT REPRESENT A WINDOW SAVED BY "SAVEWIND".
  1180.               IT MUST REPRESENT A WINDOW SAVED BY "MAKEWIND".
  1181.  
  1182.  
  1183.  
  1184.                                        14
  1185.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  1186.  
  1187.  
  1188.  
  1189.  
  1190.  
  1191.  
  1192.  
  1193.  
  1194.  
  1195.          1.03 PRINTW (TEXT$, R%, LC%)
  1196.  
  1197.               Description:   Prints text to the active window.  Care
  1198.               must be used to assure the active window is visible
  1199.               as PRINTW will print predicated on the coordinates of
  1200.               the active window regardless of it's visibility.  It is
  1201.               advisable, therefore, to print to a window immediately
  1202.               after it is made the active window. The text's color
  1203.               will be the print-to color of the active window.  If
  1204.               no window is active when PRINTW is called an error will
  1205.               be reported.
  1206.  
  1207.               Arguments:   TEXT$ is the text to be printed.
  1208.  
  1209.                            R% is the row in the window were the text
  1210.               will print .  If R%=1 the text will print in the first
  1211.               row below the border or title box. PRINTW may be used to
  1212.               print a label in the bottom border of the window by
  1213.               setting R% to the number or rows in the active window
  1214.               minus 1 ( minus 3 if a title box was specified ).  An
  1215.               invalid value for R% will result in a reported error.
  1216.  
  1217.                            LC% is the left column where TEXT$ starts
  1218.               printing.  If LC%=100 the text will be centered left to
  1219.               right.  IF LC% plus the length of TEXT$ is greater than
  1220.               the windows width minus 2 an error will be reported.
  1221.  
  1222.  
  1223.          1.04 PRINTWHOT ( TEXT$, R%, LC%, HOTCHARPOS%, HOTATTR% )
  1224.  
  1225.               Description:   Prints text to the active window.  Prints
  1226.               one character ( the "hot character" ) in a different
  1227.               color.  Care must be used to assure the active window is
  1228.               visible as PRINTWHOT will print predicated on the
  1229.               coordinates of the active window regardless of it's
  1230.               visibility.  It is advisable therefore, to print to a
  1231.               window immediately after it is made the active window.
  1232.               The text's color ( excluding the "hot character" ) will be
  1233.               the print-to color of the active window.  If no window is
  1234.               active when PRINTWHOT is called an error will be reported.
  1235.  
  1236.               Arguments:     TEXT$ is the text to be printed.  R% is the
  1237.               row in the window were the text will print .  If R%=1 the
  1238.               text will print in the first row below the border or title
  1239.               box. PRINTW may be used to print a label in the bottom
  1240.               border of the window by setting R% to the number or rows
  1241.               in the active window minus 1 ( minus 3 if a title box was
  1242.               specified ).  An invalid value for R% will result in a
  1243.               reported error.
  1244.  
  1245.                               LC% is the left column where TEXT$ starts
  1246.               printing.  If LC%=100 the text will be centered left to
  1247.  
  1248.  
  1249.  
  1250.                                        15
  1251.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  1252.  
  1253.  
  1254.  
  1255.  
  1256.  
  1257.  
  1258.  
  1259.  
  1260.  
  1261.               right.  IF LC% plus the length of TEXT$ is greater than
  1262.               the windows width minus 2 an error will be reported.
  1263.  
  1264.                              HOTCHARPOS% is the position in TEXT$ of the
  1265.               "hot character".
  1266.  
  1267.                              HOTATTR% is the color or the "hot
  1268.               character".  ( SEE THE COLOR ATTRIBUTE CHART IN THE
  1269.               APPENDIX. )
  1270.  
  1271.  
  1272.          1.05 SAVEWIND (W%, TR%, LC%, WIDE%, NR%)
  1273.  
  1274.               Description:   Saves a portion of the screen in window
  1275.               memory.  This procedure is the same as MAKEWIND except
  1276.               no window is made.  The area designated by the arguments
  1277.               is saved.  If the number assigned to W% represents a
  1278.               window area previously saved by MAKEWIND or SAVEWIND an
  1279.               error is reported.  An area saved via SAVEWIND can be
  1280.               "popped" to the screen at appropriate times during
  1281.               program execution by RSTRWIND ( see description ). A
  1282.               screen area saved by SAVEWIND DOES NOT BECOME THE
  1283.               ACTIVE WINDOW.  SAVEWIND differs from RESAVE in that it
  1284.               saves an area of the screen specified by it's
  1285.               arguments. RESAVE saves the area of the screen as
  1286.               designated by the coordinates of the active window.
  1287.  
  1288.  
  1289.               Arguments:  W% must range from 1 to 20.
  1290.  
  1291.                           See MAKEWIND for a description of the
  1292.               remaining arguments.
  1293.  
  1294.  
  1295.  
  1296.          1.06 RESAVE
  1297.  
  1298.               Description:   Saves the active window, it's interior,
  1299.               and shadow.  As window number 0 can not be saved the
  1300.               active window can not be window number 0.  If there is
  1301.               no active window or window number 0 is active when
  1302.               RESAVE is called an error will be reported.
  1303.  
  1304.               The screen area saved under the active window is removed
  1305.               from window memory and replaced with the active window
  1306.               and it's interior.   After complex screens are made in
  1307.               the active window's interior, RESAVE can be used to save
  1308.               them.   They can be restored to the screen using
  1309.               RSTRWIND.  Use RESAVE immediately after a window is made
  1310.               and it's interior is filled as  RESAVE will save the
  1311.               area of the screen determined by the active window's
  1312.               coordinates, even if it is not visible.
  1313.  
  1314.  
  1315.  
  1316.                                        16
  1317.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  1318.  
  1319.  
  1320.  
  1321.  
  1322.  
  1323.  
  1324.  
  1325.  
  1326.  
  1327.               Use RESAVE as follows;
  1328.  
  1329.               1. Make a window number 1 to 20 via a call to MAKEWIND.
  1330.                  This becomes the active window.
  1331.  
  1332.               2. Print in the window using PRINTW, LINEW, or BOXW.
  1333.  
  1334.               3. Call CHNGWIND to make the window number used in step
  1335.                  1 the active window.  ( Only required if additional
  1336.                  windows were made inside the original window. )
  1337.  
  1338.               4. Call RESAVE to save active window.
  1339.  
  1340.               5. Use RSTRWIND to "pop" the window and it's interior on
  1341.                  the screen any time during program execution.
  1342.  
  1343.               6. After the window is restored to the screen it may be
  1344.                  printed in again provided it is the active window.
  1345.                  This may require a call to CHNGWIND.
  1346.  
  1347.               Arguments:   None.
  1348.  
  1349.  
  1350.          1.07 RSTRWIND (W%, DELFLAG%)
  1351.  
  1352.               Description:   Restores a window are  previously saved
  1353.               by MAKEWIND, SAVEWIND or RESAVE.  The window area (W%)
  1354.               must exist in window memory or RSTRWIND does nothing.
  1355.  
  1356.               NOTE: WHEN A WINDOW IS RESTORED IT IS THE PROGRAMMER'S
  1357.               RESPONSIBILITY TO ASSURE THE SCREEN MODE IS THE SAME AS
  1358.               IT WAS WHEN IT WAS MADE.  IF A WINDOW IS MADE IN THE 43
  1359.               ROW SCREEN MODE IT MUST BE RESTORED IN SAME.
  1360.  
  1361.               Arguments:     W% is the number ( 1 to 20 ) assigned to
  1362.               the saved window area to be restored to the screen.  The
  1363.               window area is returned to it's original coordinates.
  1364.  
  1365.                              DELFLAG% is set to zero  to keep the
  1366.               windowed area in window memory.  If the DELFLAG% is not
  1367.               zero the saved window area (W%) is deleted from window
  1368.               memory. If W% was the active window an active window
  1369.               will no longer exist.
  1370.  
  1371.  
  1372.          1.08 DELWIND (W%)
  1373.  
  1374.               Description:   Deletes a saved window area (W%) from
  1375.               window memory, if it exists in window memory.  If the
  1376.               window is the active window an active window will no
  1377.               longer exist.
  1378.  
  1379.  
  1380.  
  1381.  
  1382.                                        17
  1383.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  1384.  
  1385.  
  1386.  
  1387.  
  1388.  
  1389.  
  1390.  
  1391.  
  1392.  
  1393.               NOTE: DELWIND DOES NOT RESTORE THE "SAVED" WINDOW AREA
  1394.               TO THE DISPLAY.  IT ONLY REMOVES THE "SAVED" WINDOW AREA
  1395.               FROM WINDOW MEMORY.  ROUTINE RSTRWIND MUST BE USED TO
  1396.               RESTORE THE "SAVED" WINDOW AREA TO THE DISPLAY.
  1397.  
  1398.               Argument:      W% is the window area number.
  1399.  
  1400.  
  1401.          1.09 CLRWIND
  1402.  
  1403.               Description:   Clears the interior of the active window.
  1404.               Care must be taken to assure that active window is
  1405.               visible as CLRWIND clears the area of the screen
  1406.               designated as the interior of the active window regard-
  1407.               less of the window's visibility.  The window will be
  1408.               cleared with it's print-to color.  If no window is
  1409.               active when CLRWIND is called, an error is reported.
  1410.  
  1411.               Arguments:     None
  1412.  
  1413.  
  1414.          1.10 NEWCOLOR ( ATTR% )
  1415.  
  1416.               Description:   Changes the print-to color of the active
  1417.               window.  Text printed in the window by PRINTW, lines
  1418.               printed in the window by LINEW, and boxes printed by BOXW
  1419.               will assume the new color specified by this routine.  If
  1420.               the active window is cleared via a call to CLRWIND, it's
  1421.               interior will be cleared with the color specified by
  1422.               NEWCOLOR.  The color designation will be retained and used
  1423.               by subsequent calls to PRINTW or LINEW for the window
  1424.               which was active when NEWCOLOR was called. If no window is
  1425.               active when NEWCOLOR is called, an error is reported.
  1426.  
  1427.               Argument:      ATTR% is the new color attribute.  SEE
  1428.               THE COLOR ATTRIBUTE CHART IN THE APPENDIX.
  1429.  
  1430.          1.11 LINEW ( ROW%, TYP% )
  1431.  
  1432.               Description:   Prints, or erases a line in the active
  1433.               window.  If an active window does not exist an error is
  1434.               reported. The line will assume the print-to color of the
  1435.               active window.  As the border characters are changed
  1436.               when a line is printed, the color of the border
  1437.               characters may change also.  This will occur if the
  1438.               print-to color is not the same as the color of the
  1439.               border characters in the active window.
  1440.  
  1441.               Arguments:     ROW% is the row, of the interior, of the
  1442.               active window where a line will print.  If ROW% < 1 or
  1443.               ROW% greater then the number of rows in the interior of
  1444.               the active window an error will be reported.
  1445.  
  1446.  
  1447.  
  1448.                                        18
  1449.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  1450.  
  1451.  
  1452.  
  1453.  
  1454.  
  1455.  
  1456.  
  1457.  
  1458.  
  1459.                              TYP% is the type of line which will print
  1460.               and may be as follows;
  1461.  
  1462.                       TYP%               Line type
  1463.  
  1464.                         1                Single line
  1465.                         2                Double line
  1466.                         0                Erases a line and returns
  1467.                                          normal border characters.
  1468.                         Other values     Defaults to single line.
  1469.  
  1470.  
  1471.               NOTE: IF TYP% = 0 ANY TEXT ON LINE ( ROW% ) IN THE WINDOW
  1472.                     WILL BE ERASED.
  1473.  
  1474.  
  1475.          1.12 BOXW ( TR%, LC%, WD%, NR%, BORDER% )
  1476.  
  1477.               Description: Draws a box in the active window.  The box is
  1478.               drawn in the "print-to" color.  If an attempt is make to
  1479.               make a box that will not fit entirely within the active
  1480.               window an error will be reported.  An active window must
  1481.               exist or an error will be reported.
  1482.  
  1483.               Arguments:   TR% is the top row of the box relative to the
  1484.               active window's top interior row.
  1485.  
  1486.                            LC% is the left column position of the box
  1487.               relative to the active window's left border.
  1488.  
  1489.                            WD% specifies the boxes width.
  1490.                            NR% specifies the number of rows for the box.
  1491.  
  1492.                            BORDER% sets the boxes border and may be set
  1493.               as follows.
  1494.  
  1495.                            BORDER%  Border
  1496.  
  1497.                            0        no border - may be used to erase an
  1498.                                     existing box.
  1499.                            1        single line border.
  1500.                            2        double line border.
  1501.  
  1502.                            Other values default to BORDER% = 1.
  1503.  
  1504.  
  1505.  
  1506.  
  1507.  
  1508.  
  1509.  
  1510.  
  1511.  
  1512.  
  1513.  
  1514.                                        19
  1515.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  1516.  
  1517.  
  1518.  
  1519.  
  1520.  
  1521.  
  1522.  
  1523.  
  1524.  
  1525.          1.13 WAVAIL% ( WINDNUM% )
  1526.  
  1527.               Description: WAVAIL% is a function.  It determines if a
  1528.               window is available.  A window is available if it has
  1529.               never been used or if it has been used and subsequently
  1530.               deleted by routines RSTRWIND or DELWIND.  AS WAVAIL% IS A
  1531.               FUNCTION IT IS IMPERATIVE IT IS DECLARED IN ANY MODULE
  1532.               USING IT.  WAVAIL% equals 1 if a window is available.
  1533.               WAVAIL% equals 0 if a window is not available.
  1534.  
  1535.               Argument:    WINDNUM% is the window number.  It may range
  1536.               from 1 to 25.  Windows 1 to 20 are used in the window
  1537.               management system.  Window 22 is used for the get answer
  1538.               window in routine GETANS.  The following applies to
  1539.               windows 21, 23, 24, AND 25.
  1540.  
  1541.               WINDOW#  WAVAIL%   MEANING
  1542.                        =
  1543.               21       0         There is an active input window. It
  1544.                                  may be deleted by routine RSTRINPT. A
  1545.                                  call to INPTWIND re-enters the active
  1546.                                  input window.
  1547.               21       1         There is no active input window.
  1548.                                  Calling INPTWIND will make a new active
  1549.                                  input window.
  1550.  
  1551.               23       0         There is an active pulldown window. It
  1552.                                  may be deleted by routine RSTRPULL.  A
  1553.                                  call to PULLDOWN re-enters the active
  1554.                                  pulldown window.
  1555.               23       1         There is no active pulldown window.
  1556.                                  Calling PULLDOWN will place the user at
  1557.                                  the first selection of the pulldown
  1558.                                  menubar.
  1559.  
  1560.               24       0         There is an active pulldown menubar. It
  1561.                                  may be deleted by routine RSTRPULL.  A
  1562.                                  call to pulldown will not save the
  1563.                                  display area occupied by the menubar.
  1564.  
  1565.               24       1         There is no active pulldown menubar.
  1566.                                  Calling PULLDOWN will make an active
  1567.                                  menubar and save the display area
  1568.                                  occupied by same.
  1569.  
  1570.               25       0         There is an active info-line.  It may
  1571.                                  be deleted by routine RSTRINFO. Calls
  1572.                                  to PRINTINFO will print in the info-
  1573.                                  line.
  1574.               25       1         There is no active info-line.  Calling
  1575.                                  INFOLINE will make an active info-line
  1576.  
  1577.  
  1578.  
  1579.  
  1580.                                        20
  1581.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  1582.  
  1583.  
  1584.  
  1585.  
  1586.  
  1587.  
  1588.  
  1589.  
  1590.  
  1591.          1.14 WINDSTATUS
  1592.  
  1593.               Description:   This is a programming tool.  Calling
  1594.               WINDSTATUS reports window 0 to 20's. number, top row,
  1595.               left column, width, number of rows, and attribute (color).
  1596.               The attribute refers to the original attribute specified
  1597.               by the call to MAKEWIND for each window.  If the
  1598.               attribute is "SAVED" the window area was saved by a call
  1599.               to SAVEWIND, not MAKEWIND.  WINDSTATUS also reports the
  1600.               active window and total window memory used to save
  1601.               window areas.   Window number zero does not use window
  1602.               memory as the area under it is not saved.  To use
  1603.               WINDSTATUS place a call to WINDSTATUS in the program at
  1604.               the location where it is desirable to view each windows
  1605.               parameters.  The program will terminate and must be
  1606.               restarted.  First remove the call to WINDSTATUS.
  1607.  
  1608.               NOTE: IF A WINDOW HAS A SHADOW IT'S WIDTH IS INCREASED
  1609.                     BY TWO AND IT'S LENGTH IS INCREASED BY ONE.
  1610.  
  1611.               Arguments:   None.
  1612.  
  1613.  
  1614.  
  1615.  
  1616.  
  1617.  
  1618.  
  1619.  
  1620.  
  1621.  
  1622.  
  1623.  
  1624.  
  1625.  
  1626.  
  1627.  
  1628.  
  1629.  
  1630.  
  1631.  
  1632.  
  1633.  
  1634.  
  1635.  
  1636.  
  1637.  
  1638.  
  1639.  
  1640.  
  1641.  
  1642.  
  1643.  
  1644.  
  1645.  
  1646.                                        21
  1647.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  1648.  
  1649.  
  1650.  
  1651.  
  1652.  
  1653.  
  1654.  
  1655.  
  1656.  
  1657.                         ***** PULLDOWN WINDOWS *****
  1658.  
  1659.          These procedures generate a maximum of 10 pulldown windows.
  1660.          The area covered by the pulldown windows is saved and restored as
  1661.          the window moves from one menubar item to the next.  To select a
  1662.          menubar item the ARROW keys can be used or the first letter of
  1663.          the menubar item may be pressed.  To select an item from any of
  1664.          the pulldown windows the ARROW keys, or "KEY CHARACTER" for the
  1665.          item may be pressed.  If the ARROW keys are used the ENTER or
  1666.          RETURN key must be pressed to finalize the selection.  If a
  1667.          letter is pressed, and it is found, the procedure is
  1668.          automatically exited without the need to press the ENTER or
  1669.          RETURN keys.  The ESC and FUNCTION keys may optionally exit.
  1670.  
  1671.  
  1672.  
  1673.  
  1674.          2.00 SETPULL ( TR%, LC% , WD%, PWIND$() )
  1675.  
  1676.               Description: Must be called to set up the routine
  1677.               PULLDOWN.  Must be called prior to calling routines
  1678.               PULLDOWN or CHNGPULL.
  1679.  
  1680.               Arguments:   TR% is the top row position of the menubar.
  1681.               If the top row position of the menubar is set too low not
  1682.               allowing a pulldown window to fit on the display an error
  1683.               will be reported ( WINDOW WON'T FIT or SHADOW WON'T FIT )
  1684.               when the pulldown window is accessed.
  1685.  
  1686.                            LC% is the left column position of the
  1687.               menubar.  It must range from 1 to 73.  If the left column
  1688.               position of the menubar is set too high not allowing a
  1689.               pulldown window to fit on the display an error will be
  1690.               reported ( WINDOW WON'T FIT or SHADOW WON'T FIT ) when
  1691.               the pulldown window is accessed.
  1692.  
  1693.                            WD% is the width of the menubar.  WD% is
  1694.               self adjusting if it is set outside of the permissible
  1695.               range.  The maximum width of the menubar is 81 - LC%.
  1696.               The minimum width of the menubar equals the width of the
  1697.               individuals items in the menubar plus two spaces between
  1698.               each item plus two preceding spaces and one trailing
  1699.               space.  If WD% is set too low it self adjusts to the
  1700.               minimum width.  If it is set too high it self adjusts to
  1701.               the maximum width.  WD% only changes the length, by
  1702.               adding trailing spaces to the menubar, if it is greater
  1703.               then the minimum width and less then or equal to the
  1704.               maximum width of the menubar.
  1705.  
  1706.                             PWIND$() is an array containing strings
  1707.               representing menubar selections, the data for the info-
  1708.               line for the menubar selections, and the individual
  1709.  
  1710.  
  1711.  
  1712.                                        22
  1713.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  1714.  
  1715.  
  1716.  
  1717.  
  1718.  
  1719.  
  1720.  
  1721.  
  1722.  
  1723.               pulldown window selections.  PWIND$() must be in the
  1724.               correct format.  The last selection in each pulldown
  1725.               window must be followed by a "***" in PWIND$().
  1726.               "ENDPULL" in PWIND$() marks the end of all pulldown
  1727.               windows.  PWIND$(1) must be the first string in the
  1728.               array, NOT PWIND$(0).  The following represents an
  1729.               example of the required format for PWIND$() for a
  1730.               pulldown window ( the first pulldown window ).
  1731.  
  1732.               EXAMPLE:
  1733.  
  1734.               PWIND$(1) = "File"               ' Menubar selection for
  1735.               ( SEE BELOW )                    ' pulldown window one.
  1736.  
  1737.               PWIND$(2) = "File operations"    ' This will print in
  1738.               NOTE: MUST = "" IF INFO-LINE     ' the info-line for
  1739.               IS NOT USED.                     ' menubar selection 1
  1740.               PWIND$(3) = "Save"               ' Selections for the
  1741.               PWIND$(4) = "Get"                ' pulldown window.
  1742.               PWIND$(5) = "Delete"
  1743.  
  1744.               PWIND$(6) = "***"                ' End of pulldown
  1745.                                                ' window.
  1746.  
  1747.               PWIND(7) = ........              ' Start over for next
  1748.                                                ' pulldown window.
  1749.  
  1750.               PWIND(?? - 1) = "***"            ' End of last pulldown
  1751.                                                ' window.
  1752.  
  1753.               PWIND(??) = "ENDPULL"            ' End of all pulldown
  1754.                                                  data.
  1755.  
  1756.               In the above example PWIND$(1) holds the menubar selection
  1757.               for the first pulldown window.  The menubar defaults to
  1758.               two spaces between selections. If PWIND$(1) = "File  " two
  1759.               additions spaces will be inserted between "File" and the
  1760.               next menubar selection.  Only trailing spaces are
  1761.               considered.  Leading spaces are removed.  PWIND$(2) holds
  1762.               the data for the info-line ( SEE ROUTINE INFOLINE ) for
  1763.               the first menubar selection, "File".  For every menubar
  1764.               selection in PWIND$() the following element of PWIND$()
  1765.               MUST contain info-line data.  If an info-line is not used
  1766.               set the appropriate elements of PWIND$ to equal "".
  1767.               Pulldown window selections follow the info-line data in
  1768.               PWIND$(). Each element of PWIND$() which represents a
  1769.               pulldown window selection has a "KEY CHARACTER".  The key
  1770.               character is the character which is searched for when a
  1771.               key is pressed while in the PULLDOWN window environment.
  1772.               The key character defaults to the first character in each
  1773.               item.  To designate the key character as a different
  1774.               character follow the character with a "@".  THIS IS ONLY
  1775.  
  1776.  
  1777.  
  1778.                                        23
  1779.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  1780.  
  1781.  
  1782.  
  1783.  
  1784.  
  1785.  
  1786.  
  1787.  
  1788.  
  1789.               APPLICABLE TO THE PULLDOWN WINDOW SELECTIONS.  THE
  1790.               PULLDOWN MENUBAR SELECTIONS ALWAYS DEFAULT TO THE FIRST
  1791.               CHARACTER.  IF A "@" IS PLACED IN A MENUBAR STRING IT WILL
  1792.               PRINT AS PART OF THE MENUBAR.
  1793.  
  1794.               EXAMPLES:
  1795.               PWIND$(3) = "Get File"        ( Key character = "G")
  1796.               PWIND$(4) = "Save F@ile"      ( Key character = "F")
  1797.  
  1798.               The "@" will not be displayed when the string is printed
  1799.               in the pulldown window.  The description for KEYATTR%
  1800.               for the routine PULLDOWN describes how to make the key
  1801.               character a different color, or high intensity, enabling
  1802.               users to distinguish it as the key character.
  1803.  
  1804.               NOTE: DO NOT PLACE THE "@" IN POSITION ONE OR TWO OF THE
  1805.               STRING AS IT WILL PRINT IN THE PULLDOWN WINDOW.  AS
  1806.               STATED THE KEY CHARACTER WILL DEFAULT TO POSITION ONE IF
  1807.               THE "@" IS OMITTED FROM THE STRING.  THIS ELIMINATES THE
  1808.               NEED TO PLACE THE "@" IN POSITION TWO.
  1809.  
  1810.               If an element of PWIND$() = "-" and it is not the first
  1811.               or last item in a pulldown window it will segment the
  1812.               pulldown window by placing a line across the width of it.
  1813.               If the "-" is the first or last item in the pulldown
  1814.               window it will print as a "-".
  1815.  
  1816.               EXAMPLE:  PWIND$(4) = "-"   Providing PWIND$(4) is not
  1817.                         last item in the pulldown window PWIND$(4) will
  1818.                         print as a line across the window.
  1819.  
  1820.               --------------------------------------------------------
  1821.               EXAMPLE: SETPULL
  1822.  
  1823.               N%=30                           ' USE THIS METHOD SO
  1824.               DIM PWIND$(N%)                  ' PWIND$() IS DYNAMIC.
  1825.                                               ' DON'T USE DIM PWIND$(30).
  1826.               TEMP%=0
  1827.               WHILE PWIND$(TEMP%) <> "ENDPULL"
  1828.                  TEMP% = TEMP% + 1            ' TEMP% MUST START WITH 1.
  1829.                  READ PWIND$(TEMP%)           ' READ PULLDOWN WINDOW DATA.
  1830.               WEND
  1831.               TR%=1: LC%=1: WD%=80            ' MENUBAR'S LOCATION/WIDTH.
  1832.  
  1833.               CALL SETPULL ( TR%, LC%, WD%, PWIND$() )  'SET PULLDOWN
  1834.               ERASE PWIND$                    ' COMPLETELY ERASES PWIND$()
  1835.                                               ' IF IT IS DYNAMIC.
  1836.               DATA THIS                  :' MENUBAR SELECTION FOR PULL-
  1837.                                          :'  DOWN WINDOW #1.
  1838.               DATA Sample window 1       :' INFO-LINE FOR MENUBAR
  1839.                                          :' SELECTION FOR WINDOW 1.
  1840.               DATA HELLO, JOE,***        :' WINDOW #1 SELECTIONS
  1841.  
  1842.  
  1843.  
  1844.                                        24
  1845.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  1846.  
  1847.  
  1848.  
  1849.  
  1850.  
  1851.  
  1852.  
  1853.  
  1854.  
  1855.               DATA IS                    :' MENUBAR SELECTION - WINDOW 2.
  1856.               DATA Sample window 2       :' INFO-LINE FOR MENUBAR SELECTION.
  1857.               DATA HOW, ARE, -, YOU,***  :' WINDOW #2 SELECTIONS.
  1858.                                          :' LINE PRINTED IN ROW 3
  1859.  
  1860.               DATA A                     :' MENUBAR SELECTION - WINDOW 3.
  1861.               DATA Sample window 3       :' INFO-LINE FOR MENUBAR SELECTION.
  1862.               DATA I,AM@,FINE,***        :' WINDOW 3 SELECTIONS.  "AM" HAS
  1863.                                          :' A KEY CHARACTER OF "M".
  1864.  
  1865.               DATA SAMPLE                :' MENUBAR SELECTION - WINDOW 4.
  1866.               DATA Sample window 4       :' INFO-LINE FOR MENUBAR SELECTION.
  1867.               DATA BYE,***               :' WINDOW 4 SELECTION - ONE ITEM.
  1868.  
  1869.  
  1870.               DATA ENDPULL               :' END OF DATA ( CASE SENSITIVE )
  1871.               --------------------------------------------------------
  1872.               Array PWIND$() is dimensioned to hold the pulldown menubar,
  1873.               info-line, and window data.  This is only a temporary array
  1874.               to hold the data and is erased after SETPULL is called.
  1875.               The data is then read.  The "***" signals the end of each
  1876.               pulldown window and MUST be entered exactly as shown. The
  1877.               "ENDPULL" signals the end for all pulldown windows and MUST
  1878.               be the last data item read.  If the format is not exactly
  1879.               as shown an error will be reported or the windows will not
  1880.               be as expected.  In the example shown the first menubar
  1881.               item is "THIS".  It's associated pulldown window contains
  1882.               the two items "HELLO" and "JOE".  When "THIS" is selected
  1883.               the info-line, if it is on, will display "Sample window 1".
  1884.               The last menubar item is "SAMPLE" and it's pulldown window
  1885.               contains one item "BYE".  When "SAMPLE" is selected the
  1886.               info-line will display "Sample window 3".  The menubar is
  1887.               located on line 1, column 1 ( TR%=1 and LC% = 1 ). It
  1888.               occupies the entire row as WD% = 80.
  1889.  
  1890.               NOTE: THE DATA MUST BE IN THE FORMAT SHOWN.  THE CHAR-
  1891.               ACTERS "***" MARK THE END OF EACH INDIVIDUAL WINDOW AND
  1892.               THE WORD "ENDPULL" MARKS THE END OF ALL PULLDOWN WINDOWS.
  1893.  
  1894.  
  1895.          2.01 PULLDOWN (INFO$(),BAR%,WIND%,EX$,RKEY%,ATTR%,KEYATTR%,BRDR%)
  1896.  
  1897.               NOTE 1: ROUTINE "SETPULL" MUST BE CALLED ONCE PRIOR TO
  1898.               CALLING THIS ROUTINE.
  1899.  
  1900.               NOTE 2: ROUTINE "RSTRPULL" MUST BE CALLED AFTER THIS
  1901.               ROUTINE IS EXITED TO DEACTIVATE THE ACTIVE PULLDOWN WINDOW
  1902.               AND RESTORE THE DISPLAY AREAS UNDER THE ACTIVE PULLDOWN
  1903.               WINDOW AND MENUBAR.  IF "RSTRPULL" IS NOT CALLED THE
  1904.               ACTIVE PULLDOWN WINDOW AND MENUBAR REMAIN ACTIVE.
  1905.               ( *** SEE RSTRPULL *** )
  1906.               Description: Places the user in the pulldown window
  1907.  
  1908.  
  1909.  
  1910.                                        25
  1911.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  1912.  
  1913.  
  1914.  
  1915.  
  1916.  
  1917.  
  1918.  
  1919.  
  1920.  
  1921.               environment.  On entering PULLDOWN, the following occurs.
  1922.  
  1923.               1. IF AN ACTIVE PULLDOWN WINDOW DOES NOT EXIST the scroll
  1924.                  bar will be positioned over first selection in the
  1925.                  pulldown menubar.
  1926.  
  1927.               2. IF AN ACTIVE PULLDOWN WINDOW EXISTS the scroll bar will
  1928.                  be positioned over the active pulldown selection in the
  1929.                  active pulldown window ( SEE RSTRPULL ).  This may be
  1930.                  appropriate if a selection from a pulldown window is
  1931.                  used to present the user with selections from another
  1932.                  scroll window external to PULLDOWN.  If the user
  1933.                  presses ESC to exit the external scroll window PULLDOWN
  1934.                  may be re-entered exactly where it was exited.  IN THIS
  1935.                  CASE THE ACTIVE PULLDOWN WINDOW MUST BE INTACT.  IT
  1936.                  WILL NOT BE COMPLETELY RE-PRINTED. If the user makes a
  1937.                  selection from the external scroll window, the routine
  1938.                  RSTRPULL may be used to restore the area under the
  1939.                  pulldown window and deactivate the active pulldown
  1940.                  window. The next call to PULLDOWN displays the pulldown
  1941.                  menubar with the scroll bar positioned over the first
  1942.                  item.
  1943.  
  1944.               IF AN ACTIVE PULLDOWN WINDOW UNKNOWINGLY EXISTS ON ENTRY
  1945.               TO PULLDOWN THE ACTIVE PULLDOWN WINDOW, IF NOT DISPLAYED,
  1946.               WILL HAVE IT'S INTERIOR PARTIALLY REPRINTED.  THE WINDOW
  1947.               WILL NOT BE RE-PRINTED.
  1948.  
  1949.               Arguments:   INFO$() is a string array holding the data
  1950.               for the info-line ( SEE ROUTINE INFOLINE ) for each
  1951.               pulldown windows's selections.  Do not confuse this with
  1952.               the info-line data which is associated with the menubar
  1953.               selections as defined in routine SETPULL.  The info-line
  1954.               provides instructions or descriptions for the selections
  1955.               in the pulldown windows.  If pulldown window one holds
  1956.               five selections, INFO$(1) holds the data for the first
  1957.               selection in the window.  INFO$(2) is the data for the
  1958.               second selection.  Corresponding elements of INFO$() and
  1959.               the pulldown window's selections are related.  A
  1960.               SEGMENTING LINE IN A PULLDOWN WINDOW MUST BE REPRESENTED
  1961.               BY A "" IN INFO$().  If pulldown window one contains
  1962.               five selections and pulldown window two contains ten
  1963.               selections, INFO$(6) will hold the data for the info-
  1964.               line for the first selection in the pulldown window two
  1965.               while INFO$(15) will hold the data for the info-line for
  1966.               the last selection.  The elements of INFO$() will only
  1967.               be displayed in the info-line if it is "turned on" via
  1968.               routine INFOLINE.  IF AN INFO-LINE IS NOT USED INFO$()
  1969.               MUST STILL BE A PREVIOUSLY DIMENSION ARRAY.  DIMENSION
  1970.               INFO$() TO ZERO BEFORE CALLING PULLDOWN.
  1971.  
  1972.               EXAMPLE: DIM INFO$(0)       'IF INFO-LINE IS NOT USED
  1973.  
  1974.  
  1975.  
  1976.                                        26
  1977.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  1978.  
  1979.  
  1980.  
  1981.  
  1982.  
  1983.  
  1984.  
  1985.  
  1986.  
  1987.  
  1988.               Using the example for the pulldown windows defined in
  1989.               the call to SETPULL ( SEE - EXAMPLE: SETPULL ) the
  1990.               following could apply to INFO$()
  1991.  
  1992.               EXAMPLE: DIM INFO$(10)      ' DO NOT ERASE THIS ARRAY!!!
  1993.  
  1994.                   INFO$()                 ' RELATED PULLDOWN SELECTION
  1995.                   ----------------------------------------------------
  1996.  
  1997.                   INFO$(1) = "ONE"        ' WINDOW 1 SELECTION "HELLO"
  1998.                   INFO$(2) = "TWO"        ' WINDOW 1 SELECTION "JOE"
  1999.  
  2000.                   INFO$(3) = "THREE"      ' WINDOW 2 SELECTION "HOW"
  2001.                   INFO$(4) = "FOUR"       ' WINDOW 2 SELECTION "ARE"
  2002.                   INFO$(5) = ""           ' WINDOW 2 -- LINE
  2003.                   INFO$(6) = "FIVE"       ' WINDOW 2 SELECTION "YOU"
  2004.                   INFO$(7) = "SIX"        ' WINDOW 3 SELECTION "I"
  2005.                   INFO$(8) = "SEVEN"      ' WINDOW 3 SELECTION "AM"
  2006.                   INFO$(9) = "EIGHT"      ' WINDOW 3 SELECTION "FINE"
  2007.  
  2008.                   INFO$(10) = "NINE"      ' WINDOW 4 SELECTION "BYE"
  2009.  
  2010.                   The numbers ONE, TWO, THREE .... will print in the
  2011.                   info-line when the corresponding pulldown window
  2012.                   selection is covered by the scroll bar.
  2013.  
  2014.  
  2015.                            BAR% is the sequential number (left to right)
  2016.               of selected menubar item . It is returned by the calling
  2017.               procedure, PULLDOWN.  If the second item in the menubar is
  2018.               selected, BAR% will equal two.  If ESC is pressed and
  2019.               ESC is an exit key BAR% will equal 0 on exit.  If a
  2020.               function key is pressed and it is an exit key, BAR% will
  2021.               equal the highlighted menubar selection on exit.
  2022.  
  2023.                            WIND% represents the row number of the
  2024.               selected pulldown window item.  It is returned by the
  2025.               calling procedure.  If the ESC pressed and ESC is an exit
  2026.               key, WIND% will equal 0 on exit.  If a function key is
  2027.               pressed and it is an exit key, WIND% will equal the
  2028.               highlighted pulldown window selection ( interior row
  2029.               number ) on exit.
  2030.  
  2031.               NOTE:  A SEGMENTING LINE IN A PULLDOWN WINDOW OCCUPIES A
  2032.               ROW POSITION.
  2033.  
  2034.                            EX$ sets the keys which will, when pressed,
  2035.               exit PULLDOWN.  The ENTER ( RETURN ) key always exits.
  2036.  
  2037.               EX$ can be used to simulate a selection from a pulldown
  2038.               window. ( SEE DESCRIPTION FOR ARGUMENT RKEY% ).  EX$ may
  2039.  
  2040.  
  2041.  
  2042.                                        27
  2043.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  2044.  
  2045.  
  2046.  
  2047.  
  2048.  
  2049.  
  2050.  
  2051.  
  2052.  
  2053.               be any combination of the following.
  2054.  
  2055.                     "0"             The F10 key will exit.
  2056.                     "1" to "9"      The F1 to F9 key will exit.
  2057.                     "E"             The ESC key will exit.
  2058.  
  2059.               EXAMPLE: EX$ = "E24"  The ESC, F2, F4 and ENTER keys exit.
  2060.  
  2061.                            RKEY% returns a numeric representation for
  2062.               the key which was pressed to cause the exit from PULLDOWN.
  2063.               On exit RKEY% may equal the following.
  2064.  
  2065.                     1 to 10         The F1 to F10 key caused the exit.
  2066.                     13              The ENTER key caused the exit.
  2067.                     27              The ESC key caused the exit.
  2068.  
  2069.  
  2070.               Arguments EX$ and RKEY% to may be used to simulate a
  2071.               selection from a pulldown window.  To use the F1 key to
  2072.               simulate the first selection from the second pulldown
  2073.               window, argument EX$ must contain a "1" on entering
  2074.               PULLDOWN.  Check to see if the F1 key caused the exit
  2075.               ( RKEY% = 1 ) from PULLDOWN.   If it did set BAR% to 2
  2076.               simulating the second pulldown window.  Set WIND% to 1 to
  2077.               simulate the first selection from the second pulldown
  2078.               window.
  2079.  
  2080.               NOTE: IF ROUTINE CHNGPULL IS USED TO DISABLE A PULLDOWN
  2081.               WINDOW'S SELECTION AND THE SELECTION MAY ALSO BE SIMULATED
  2082.               BY AN EXIT KEY, ARGUMENT EX$ MUST BE ADJUSTED ACCORDINGLY
  2083.               TO PREVENT THE EXIT KEY FROM SIMULATING THE DISABLED
  2084.               SELECTION.
  2085.  
  2086.                            ATTR% is the color.  It follows the same
  2087.               rules as described in MAKEWIND except a flashing
  2088.               foreground is not permitted. Any value over 127 is
  2089.               changed to ATTR% MOD 128.
  2090.  
  2091.                            KEYATTR% is the color of the key character
  2092.               for selections in the pulldown windows.  If KEYATTR% = 0
  2093.               the key character will be the same color as the other
  2094.               characters in each window selections.  This would be
  2095.               appropriate if the first character in each selection is
  2096.               ALWAYS the key character. Setting KEYATTR% to a different
  2097.               color, or high intensity, allows users to distinguish the
  2098.               character as the key character for each item in the list.
  2099.               Any value for KEYATTR% over 127 is changed to KEYATTR%
  2100.               MOD 128.
  2101.  
  2102.                            BRDR% is the pulldown window's border
  2103.               designation.  BRDR% can equal 0, 1, 2, 10, 11 or 12 for
  2104.               pulldown windows.  Any other value for BRDR% will
  2105.  
  2106.  
  2107.  
  2108.                                        28
  2109.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  2110.  
  2111.  
  2112.  
  2113.  
  2114.  
  2115.  
  2116.  
  2117.  
  2118.  
  2119.               result in an error.  SEE THE BORDER DESIGNATION CHART.
  2120.  
  2121.          2.02 RSTRPULL ( RSTRMENUBAR% )
  2122.  
  2123.               Description: Restores the display area under and
  2124.               deactivates the active pulldown window.  The active
  2125.               pulldown window is the displayed pulldown window when
  2126.               routine PULLDOWN is exited.  Normally a call to RSTRPULL
  2127.               will be made when PULLDOWN is exited.  There may be times,
  2128.               however, when it is desirable to leave the active pulldown
  2129.               window and menubar displayed.  If this is the case
  2130.               RSTRPULL should not be called after PULLDOWN is exited.
  2131.  
  2132.               If RSTRPULL is NOT called after PULLDOWN is exited the
  2133.               following will occur:
  2134.  
  2135.               1. The pulldown window which was active when PULLDOWN
  2136.                  was exited will remain displayed.
  2137.  
  2138.               2. The pulldown window which was active when PULLDOWN was
  2139.                  exited remains the active pulldown window. The next
  2140.                  call to PULLDOWN will return to the active pulldown
  2141.                  window with the previous ( active ) selection from the
  2142.                  pulldown window covered by the scroll bar.
  2143.  
  2144.                  NOTE: WHEN PULLDOWN IS RE-ENTERED UNDER THESE THE
  2145.                  ROUTINE, PULLDOWN, EXPECTS THE ACTIVE PULLDOWN WINDOW
  2146.                  AND MENUBAR TO BE INTACT.  IF IT IS NOT, THE PULLDOWN
  2147.                  WINDOW WILL NOT BE DISPLAYED AS EXPECTED.  IT IS
  2148.                  IMPORTANT THAT NO PORTION OF ACTIVE PULLDOWN WINDOW OR
  2149.                  MENUBAR IS "PRINTED OVER" PRIOR TO RE-ENTERING
  2150.                  PULLDOWN.
  2151.  
  2152.               Argument:    RSTRMENUBAR% determines if the area under the
  2153.               menubar is restored to the display when RSTRPULL is
  2154.               called.  If RSTRMENUBAR% = 0 the menubar will remain
  2155.               displayed after RSTRPULL is called and the menubar will
  2156.               remain active.  Subsequent calls to PULLDOWN DO NOT save
  2157.               the area under the menubar.  PULLDOWN expects the menubar
  2158.               to be intact.  If RSTRMENUBAR% = 1 the area under the
  2159.               menubar is restored to the display and the menubar is
  2160.               deactivated.  Subsequent calls to PULLDOWN save the area
  2161.               under, and display a new  menubar.  By virtue of a call to
  2162.               RSTRPULL the area under the active pulldown window is
  2163.               restored and the active pulldown window is deactivated.
  2164.               The status of argument RSTRMENUMAR% has no affect on the
  2165.               status of the active pulldown window.  It only restores
  2166.               and deactivates the menubar or allows same to remain
  2167.               active.  In either case the next call to PULLDOWN will
  2168.               position the scroll bar over the first selection of the
  2169.               menubar after a call to RSTRPULL.
  2170.               NOTE: THE SAVED DISPLAY AREA FOR THE ACTIVE PULLDOWN
  2171.  
  2172.  
  2173.  
  2174.                                        29
  2175.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  2176.  
  2177.  
  2178.  
  2179.  
  2180.  
  2181.  
  2182.  
  2183.  
  2184.  
  2185.               WINDOW RESIDES IN WINDOW NUMBER 23.  FUNCTION WAVAIL% CAN
  2186.               DETERMINE IF A PULLDOWN WINDOW IS ACTIVE.
  2187.  
  2188.               EXAMPLE: IF WVAIL%(23) = 0 ' A pulldown window is active.
  2189.                        IF WVAIL%(23) = 1 ' A pulldown window is not
  2190.                                          '  active.
  2191.  
  2192.               THE SAVED DISPLAY AREA FOR THEN MENUBAR RESIDES IN WINDOW
  2193.               NUMBER 24.  FUNCTION WVAIL% CAN DETERMINE IF THE MENUBAR
  2194.               IS ACTIVE.
  2195.  
  2196.               EXAMPLE: IF WAVAIL%(24) = 0 ' The menubar is active.
  2197.                        IF WAVAIL%(24) = 1 ' the menubar is not active.
  2198.  
  2199.  
  2200.  
  2201.  
  2202.          2.03 CHNGPULL ( BARITEM%, WINDITEM%, ATTR% )
  2203.  
  2204.               NOTE: ROUTINE SETPULL MUST BE CALLED ONCE IN EVERY PROGRAM
  2205.               BEFORE ANY CALLS TO THIS ROUTINE.
  2206.  
  2207.               Description:  Disables or enables the ability to select
  2208.               an selection or all selections, and changes the selection's
  2209.               color, in a pulldown window.
  2210.  
  2211.               Arguments:   BARITEM% is the sequential number ( left
  2212.               to right ) of the menubar selection associated with the
  2213.               item's pulldown window.
  2214.  
  2215.                            WINDITEM% is the row position of the item
  2216.               in the pulldown window's interior. If WINDITEM% = -1
  2217.               all selections in the pulldown window are affected.
  2218.  
  2219.               NOTE:  A LINE IN A PULLDOWN WINDOW OCCUPIES A ROW
  2220.               POSITION.
  2221.  
  2222.                            ATTR% serves two purposes.
  2223.  
  2224.               If ATTR% > 0 it changes the color of the item
  2225.               specified by BARITEM% and WINDITEM% to ATTR% ( SEE THE
  2226.               COLOR ATTRIBUTE CHART ). The key character in the item
  2227.               also assumes the color specified by ATTR%.  The ability
  2228.               to select the item from the pulldown window is disabled.
  2229.               Any value for ATTR% over 127 is changed to ATTR% MOD 128.
  2230.               If ATTR% = 0 the color of the item, and it's key char-
  2231.               acter is returned to it's original status as defined in
  2232.               the original call to PULLDOWN.  The ability to select
  2233.               the item is enabled.
  2234.  
  2235.  
  2236.  
  2237.  
  2238.  
  2239.  
  2240.                                        30
  2241.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  2242.  
  2243.  
  2244.  
  2245.  
  2246.  
  2247.  
  2248.  
  2249.  
  2250.  
  2251.                          ***** SCROLL WINDOWS *****
  2252.  
  2253.          SCRLWIND places a scrollable list in the active window.  A
  2254.          highlight ( scroll ) bar is placed over a specified item in
  2255.          the list and can be moved by the user via the UP and DOWN
  2256.          ARROW keys or MOUSE.  Pressing the ENTER key or MOUSE on a
  2257.          selection returns the sequential item number covered by the
  2258.          scroll bar.  The HOME, END, PG UP, and PG DN keys move the
  2259.          scroll bar as indicated.  When a key is pressed SCRLWIND checks
  2260.          to see if the key matches the KEY CHARACTER of any selection in
  2261.          the list.  If a match is found the scroll bar moves to that
  2262.          position in the list.
  2263.  
  2264.          Based on the number of buttons ( SEE ARGUMENT BUT% ), the
  2265.          minimum size of the window used for the scroll window varies as
  2266.          follows;
  2267.  
  2268.          # BUTTONS                    0        1       2
  2269.                                               (OK )    ( OK/CANCEL )
  2270.          MIN. WINDOW WIDTH            5        11      18
  2271.          MIN. ROWS WITH TITLEBOX      5         9       9
  2272.          MIN. ROWS WITHOUT TITLEBOX   3         7       7
  2273.  
  2274.          The size of the scrollable rows is reduced by four and the size
  2275.          of the scrollable width is reduced by six if buttons are used.
  2276.          The scrollable width must be consider if a STRING WON'T FIT
  2277.          error is encountered.
  2278.  
  2279.  
  2280.          3.00 SCRLWIND (LIST$(), INFO$(), TL$, ENTRIES%, KIND$, RTRN%,
  2281.                         LI%, FC%  RKEY%, KEYATTR%, SCROLLBAR%, BUT%)
  2282.  
  2283.               NOTE1: THE ABOVE MUST BE ON ONE LINE IN THE QB/QBX/VBDOS
  2284.               ENVIRONMENT.
  2285.  
  2286.               NOTE2: FOR ADVANCED FEATURES SEE ROUTINE B4SCRL.  THESE
  2287.               FEATURES INCLUDE THE ABILITY TO;
  2288.  
  2289.                   1. EXIT THIS ROUTINE USING DEFINABLE "EXIT KEYS".
  2290.                   2. SET MARKED ( TAGGED ) SELECTIONS ON ENTRY.
  2291.                   3. CHANGE THE COLOR OF THE "TAG" DESIGNATOR.
  2292.                   4. SUPPRESS REFRESHING OF THE SCROLL WINDOW
  2293.                      ON ENTRY TO THIS ROUTINE.
  2294.  
  2295.               Description: Places a list ( LIST$() ) in the active
  2296.               window.  The list is ENTRIES% long.  There are two classes
  2297.               of scroll windows.
  2298.  
  2299.               1. Non-virtual scroll windows.  If argument KEYATTR% does
  2300.                  not equal zero the scroll window is a non-virtual
  2301.                  scroll window.  On entry, SCRLWIND, verifies each
  2302.                  element of LIST$() will fit in the scroll window with a
  2303.  
  2304.  
  2305.  
  2306.                                        31
  2307.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  2308.  
  2309.  
  2310.  
  2311.  
  2312.  
  2313.  
  2314.  
  2315.  
  2316.  
  2317.                  leading and trailing space added to the string.  If any
  2318.                  item will not fit an error is reported.  Non-virtual
  2319.                  scroll windows may be ( SEE ARGUMENT KIND$ ) regular,
  2320.                  auto-exit, multiple mark, single mark, or list scroll
  2321.                  windows.
  2322.  
  2323.               2. Virtual scroll windows.  If argument KEYATTR% equals
  2324.                  zero, the scroll window is a virtual scroll window.
  2325.                  Virtual scroll windows allow horizontal and vertical
  2326.                  scrolling.  The LEFT ARROW and RIGHT ARROW key become
  2327.                  active.  A differently colored "key character" is not
  2328.                  permitted in a virtual scroll window as the character
  2329.                  would not be visible when it is scrolled out if the
  2330.                  window.  No checks are made to verify the string length
  2331.                  in a virtual scroll window.  Virtual scroll windows may
  2332.                  be ( SEE ARGUMENT KIND$ ) regular, auto-exit, multiple
  2333.                  mark, single mark, or list scroll windows.  If argument
  2334.                  KEYATTR% equals zero and all elements of the list will
  2335.                  fit in the window's width the scroll window assumes the
  2336.                  properties of a non-virtual scroll window making the
  2337.                  RIGHT ARROW and LEFT ARROW keys inactive.
  2338.  
  2339.               NOTE: ARGUMENT KEYATTR% DETERMINES IF A SCROLL WINDOW IS
  2340.               A VIRTUAL OR NON-VIRTUAL SCROLL WINDOW. SEE THE
  2341.               DESCRIPTION FOR KEYATTR% FOR MORE INFORMATION.
  2342.  
  2343.               Arguments:   LIST$() is the array holding the strings to
  2344.               be placed in the scroll window.  Each element of the
  2345.               array is a line in the scroll window.  If the length of
  2346.               any element is greater then the width of the window - 4
  2347.               and the scroll window is a non-virtual scroll window
  2348.               ( KEYATTR% <> 0 ) an error is reported. LIST$(1) must be
  2349.               the first string in the array, NOT LIST$(0).
  2350.  
  2351.               Each selectable item in LIST$() has a "KEY CHARACTER".
  2352.               The key character is the character which is searched for
  2353.               when a key is pressed while in the SCRLWIND environment.
  2354.               The key character defaults to the first character in
  2355.               each item.  To designate the key character as a
  2356.               different character follow the character with a "@" in
  2357.               the string.
  2358.  
  2359.               EXAMPLE: LIST$(1) = "Get File"  ( Key character = "G")
  2360.                        LIST$(2) = "Save F@ile"( Key character = "F")
  2361.  
  2362.               The "@" will not be displayed when the string is printed
  2363.               in the scroll window.  The description for KEYATTR% for
  2364.               this routine describes how to make the key character a
  2365.               different color, or high intensity, enabling users to
  2366.               distinguish it as the key character.
  2367.  
  2368.  
  2369.  
  2370.  
  2371.  
  2372.                                        32
  2373.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  2374.  
  2375.  
  2376.  
  2377.  
  2378.  
  2379.  
  2380.  
  2381.  
  2382.  
  2383.               NOTE1: DO NOT PLACE THE "@" IN POSITION ONE OR TWO OF THE
  2384.               STRING AS IT WILL PRINT IN THE SCROLL WINDOW.  AS STATED
  2385.               THE KEY CHARACTER WILL DEFAULT TO POSITION ONE IF THE
  2386.               "@" IS OMITTED FROM THE STRING.  THIS ELIMINATES THE
  2387.               NEED TO PLACE THE "@" IN POSITION ONE OR TWO.
  2388.  
  2389.               NOTE2: IF ROUTINE B4SCRL IS USED TO SET A SCROLL WINDOW'S
  2390.               EXIT CRITERIA, AND ROUTINE B4SCRL'S ARGUMENT, EXIT$,
  2391.               CONTAINS AN "X" THE "KEY CHARACTER" SEARCH FEATURE IS
  2392.               DISABLED.  DO NOT USE KEY CHARACTERS IF THIS IS THE CASE.
  2393.               ( SEE ROUTINE B4SCRL )
  2394.  
  2395.               If an element of LIST$() = "-" and it is not the first
  2396.               item in the list or the last item in the list and all of
  2397.               the items in LIST$() will fit in the window's interior
  2398.               the scroll window will be segmented.  A line will print
  2399.               across the window as determined by the position of the
  2400.               "-" in LIST$().  If the previous conditions are not met
  2401.               the string will print as a "-".
  2402.  
  2403.               EXAMPLE:  LIST$(2) = "-"  ( Provided LIST$(2) is not
  2404.                         the last item in the list and the number of
  2405.                         interior rows in the window is greater than
  2406.                         two, LIST$(2) will print as a line.)
  2407.  
  2408.                            INFO$() is an array holding the individual
  2409.               strings used for the information line for each entry in
  2410.               the scroll window ( SEE ROUTINE INFO-LINE ).  As the
  2411.               scroll bar moves from entry to entry the message in the
  2412.               info-line changes based on the element of INFO$() which
  2413.               corresponds to the selected entry in the scroll window.
  2414.               If the scroll bar is over the third entry in the scroll
  2415.               window INFO$(3) will print in the info-line, provided the
  2416.               info-line is on.  A SEGMENTING LINE IN THE SCROLL WINDOW
  2417.               MUST BE REPRESENTED BY AN ELEMENT IN INFO$().  IF A
  2418.               SEGMENTING LINE OCCUPIES THE FOURTH ROW OF THE SCROLL
  2419.               WINDOW INFO$(4) MUST EQUAL "".  If the info-line is not
  2420.               going to be used or if a fixed info-line message is to be
  2421.               printed for all entries in the scroll window INFO$() must
  2422.               still be a dimensioned array prior to calling SCRLWIND.
  2423.               FOR NO INFO-LINE OR A FIXED INFO-LINE MESSAGE INFO$() MUST
  2424.               BE DIMENSIONED TO ZERO ( EX: DIM INFO$(0) ).
  2425.  
  2426.                            TL$ is a string which will print in the title
  2427.               box of the scroll window.  TL$ is ignored if the scroll
  2428.               window does not have a title box.  TL$ is useful for
  2429.               virtual scroll windows.  When a virtual scroll window
  2430.               scrolls up and down, TL$ does not move.  When a virtual
  2431.               scroll window scrolls left and right TL$ scrolls with the
  2432.               window's interior.  TL$ can, therefore, be longer than the
  2433.               window's width when used with a virtual scroll window.
  2434.               Although TL$ may be used in other ( non-virtual ) scroll
  2435.  
  2436.  
  2437.  
  2438.                                        33
  2439.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  2440.  
  2441.  
  2442.  
  2443.  
  2444.  
  2445.  
  2446.  
  2447.  
  2448.  
  2449.               windows, the title for the scroll window can be generated
  2450.               in the call to MAKEWIND for the scroll window.
  2451.  
  2452.                            ENTRIES% is the number of elements in the
  2453.               array ( LIST$() ) to use in the scroll window.
  2454.  
  2455.                            KIND$ specifies the type of scroll window
  2456.               and may be any of the following.
  2457.  
  2458.               KIND$        DESCRIPTION ( Detail descriptions follow )
  2459.  
  2460.               "A" "AN"     Auto-exit scroll window.
  2461.               "M" "MN"     Multiple mark ( tag ) scroll window.
  2462.               "S"          Single mark ( tag ) scroll window.
  2463.               "L"          List scroll window.  No scroll bar.
  2464.               "V", "SV"    View scroll window/ Single mark view.
  2465.               "N"          Regular - scroll bar erased on exit.
  2466.               Any other value for KIND$ generates a regular scroll
  2467.               window.
  2468.  
  2469.               NOTE: AN "N" IN KIND$ ERASES THE SCROLL BAR ON EXIT.
  2470.  
  2471.               AUTO-EXIT SCROLL WINDOW ( KIND$ = "A" ) --  When in the
  2472.               scroll window environment if a key pressed matches the key
  2473.               character of an item in the scroll window the routine will
  2474.               be exited.  The scroll bar moves to the item found. The
  2475.               position of the selected item in LIST$() will be returned
  2476.               in RTRN%.  If RTRN% = 2, LIST$(2) was selected.  SCRLWIND
  2477.               will exit with RKEY% equal to 13 simulating exit via the
  2478.               ENTER (RETURN) key.
  2479.  
  2480.               NOTE: IF ROUTINE B4SCRL IS USED TO SET A SCROLL WINDOW'S
  2481.               EXIT CRITERIA AND ROUTINE B4SCRL'S ARGUMENT EXIT$ CONTAINS
  2482.               AN "X" THE AUTO-EXIT FEATURE IS DISABLED. ( SEE ROUTINE
  2483.               B4SCRL )
  2484.  
  2485.               MULTIPLE MARK SCROLL WINDOW ( KIND$ = "M" )  -- Pressing
  2486.               the <+> or INSERT key marks the item covered by the scroll
  2487.               bar.  A right arrow to the left of the item in the scroll
  2488.               window signifies it has been marked. The color of this
  2489.               arrow may be changed by routine B4SCRL.  Pressing the <->
  2490.               or DELETE key un-marks an item if it was marked.  Striking
  2491.               the PRINT ( not all systems ) key or SPACE BAR marks all
  2492.               items, unless they were all previously marked, in which
  2493.               case the PRINT ( not all systems ) key or SPACE BAR will
  2494.               un-mark all items.  Pressing the ENTER or RETURN key
  2495.               returns a coded string in KIND$ which represents the
  2496.               marked items.  If KIND$ ="" no items were marked.  If any
  2497.               items were marked KIND$ will be ENTRIES% long.  Each
  2498.               character in KIND$ will correspond to an element in
  2499.               LIST$().  If the first character of KIND$=" " LIST$(1) was
  2500.               not marked. If the second character, in KIND$ = CHR$(16),
  2501.  
  2502.  
  2503.  
  2504.                                        34
  2505.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  2506.  
  2507.  
  2508.  
  2509.  
  2510.  
  2511.  
  2512.  
  2513.  
  2514.  
  2515.               LIST$(2) was marked.  Each un-marked element of LIST$()
  2516.               will have a corresponding space (" ") in KIND$ while each
  2517.               marked element will have a corresponding right arrow
  2518.               ( CHR$(16) ) in KIND$.  See the description for function
  2519.               MARKED% for a method of decoding KIND$.  The multiple mark
  2520.               feature is disabled if a scroll window is also defined as
  2521.               a list scroll window or a single mark scroll window.
  2522.  
  2523.               NOTE: THE USE OF ROUTINE B4SCRL AFFECTS MULTIPLE MARK
  2524.               SCROLL WINDOWS AS FOLLOWS:
  2525.  
  2526.               1. IF THE INSERT OR DELETE KEYS ARE SET AS EXIT KEYS BY
  2527.                  ROUTINE B4SCRL THE INSERT AND DELETE KEYS WILL NO
  2528.                  LONGER MARK AND UN-MARK ENTRIES.  THE "+" AND "-" KEYS
  2529.                  WILL STILL MARK AND UN-MARK ENTRIES.
  2530.  
  2531.               2. IF B4SCRL'S ARGUMENT EXIT$ CONTAINS AN "X"  THE SPACE
  2532.                  BAR DOES NOT MARK/UN-MARK ALL ENTRIES.
  2533.  
  2534.               SINGLE MARK SCROLL WINDOW ( KIND$ = "S" ) --- Provided
  2535.               there is more than one item ( ENTRIES% > 1 ) in the scroll
  2536.               window, one item will be marked as in the preceding
  2537.               example for a "MULTIPLE MARK" scroll window.  Only one
  2538.               item can be marked, however.  The marked item follows the
  2539.               scroll bar.  Pressing TAB, SHIFT TAB, ENTER, RETURN or ESC
  2540.               will exit the scroll window with the selected item in
  2541.               RTRN% and a representation of the "exit key" in RKEY%.  If
  2542.               the scroll bar is over LIST$(2), RTRN% = 2 was selected.
  2543.  
  2544.               VIEW ONLY SCROLL WINDOW ( KIND$ = "V" OR "SV" ) --- The
  2545.               window will be filled with the strings in LIST$() and the
  2546.               routine will be exited.  IF KIND$ = "SV" the scroll window
  2547.               is "VIEW ONLY -SINGLE MARK" scroll window. If ENTRIES% > 1
  2548.               the item designated by the value of RTRN% will be marked.
  2549.               ( See description for RTRN%. )
  2550.  
  2551.               LIST SCROLL WINDOW ( KIND$ = "L" ) --- This generates a
  2552.               list scroll window.  There is no scroll bar.  This may be
  2553.               useful for viewing virtual scroll windows.  It may be used
  2554.               for regular scroll windows also.
  2555.  
  2556.               Any other value for KIND$ when entering SCRLWIND results
  2557.               in a "REGULAR" scroll window. After the scroll bar is
  2558.               moved to the selected item, pressing the ENTER or RETURN
  2559.               key returns the selected item in RTRN%.  Routine B4SCRL
  2560.               provides alternate means to exit SCRLWIND.
  2561.  
  2562.  
  2563.                            RTRN% serves two purposes. One is to place
  2564.               the scroll bar over the item specified by RTRN% when
  2565.               entering SCRLWIND.  If RTRN% < 1 or RTRN% > ENTRIES%,
  2566.  
  2567.  
  2568.  
  2569.  
  2570.                                        35
  2571.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  2572.  
  2573.  
  2574.  
  2575.  
  2576.  
  2577.  
  2578.  
  2579.  
  2580.  
  2581.               RTRN% defaults to 1 and the scroll bar will be positioned
  2582.               over the first item in the window.
  2583.  
  2584.               EXAMPLE: RTRN% = 2  --  If there are a minimum of two
  2585.               items in the scroll window ( ENTRIES% > 1 ) the scroll
  2586.               bar will be over LIST$(2) when entering SCRLWIND.
  2587.  
  2588.               RTRN% also returns the selected item when exiting
  2589.               SCRLWIND.   If RTRN% = 2, LIST$(2) was selected when
  2590.               SCRLWIND was exited.  If routine B4SCRL is used prior to
  2591.               calling SCRLWIND it is possible to exit SCRLWIND on any
  2592.               attempt to scroll before the first entry in the scroll
  2593.               window or past the last entry in the scroll window. This
  2594.               feature affects the value of RTRN% ( SEE ROUTINE B4SCRL).
  2595.  
  2596.               NOTE: THE ITEM SELECTED IN LIST$(), AS INDICTED BY THE
  2597.               VALUE OF RTRN%, MAY CONTAIN A "@" TO INDICATE THE KEY
  2598.               CHARACTER.  IF IT IS NECESSARY TO PRINT THE ITEM THE "@"
  2599.               CAN BE REMOVED FROM IT USING THE FOLLOWING FUNCTION.
  2600.  
  2601.               ' FUNCTIONS MUST BE DECLARED.  RTRN% = ITEM # SELECTED
  2602.               ' FROM LIST$().
  2603.  
  2604.               DECLARE FUNCTION NO$( ITEM$ )
  2605.               '( Place this at the start of the module.)
  2606.               ' IF RTRN% = 2 AND LIST$(RTRN%) = "Save F@ile", LIST$(2)
  2607.               ' CAN BE PRINTED AS "Save File" as follows.
  2608.  
  2609.               PRINT NO$( LIST$(RTRN%) )
  2610.  
  2611.               ----------------------------------------------------------
  2612.               ' INCLUDE THIS FUNCTION IN YOUR PROGRAM
  2613.  
  2614.               FUNCTION NO$ ( ITEM$ )
  2615.                 A% = INSTR ( ITEM$, "@" )
  2616.                 IF A% < 3 THEN        ' "@" SHOULD NOT BE IN POSITION
  2617.                    NO$ = ITEM$        ' 1 OR 2, OR NO "@" IS IN ITEM$.
  2618.                 ELSE
  2619.                    NO$ = LEFT$(ITEM$, A% - 1) + MID$(ITEM$, A% + 1)
  2620.                 END IF
  2621.               END FUNCTION
  2622.               ----------------------------------------------------------
  2623.  
  2624.                            LI%, on entry to routine SCRLWIND, specifies
  2625.               which row ( of the interior of the scroll window ) to
  2626.               place the scroll bar on.  It is used, on entry, with
  2627.               argument RTRN% to place the scroll bar over a specific
  2628.               entry on a specific row.  This is useful if it is
  2629.               necessary to exit a scroll window and re-enter it with the
  2630.               scroll bar over the same entry and on the same line as on
  2631.               the previous exit.  Set this argument to one if it is not
  2632.               required . The following restrictions apply.
  2633.  
  2634.  
  2635.  
  2636.                                        36
  2637.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  2638.  
  2639.  
  2640.  
  2641.  
  2642.  
  2643.  
  2644.  
  2645.  
  2646.  
  2647.               1. If LI% is less than one or LI% is greater than the
  2648.                  number of entries ( ENTRIES% ) LI% is indeterminate.
  2649.                  The scroll bar will be positioned over the entry
  2650.                  specified by argument RTRN%.
  2651.  
  2652.               2. Argument RTRN% determines the line the scroll bar will
  2653.                  occupy ( argument LI% is ignored ) if an attempt is
  2654.                  made to place an entry on a line greater than the
  2655.                  subscript of the entry.  For example, LIST$(2) can not
  2656.                  be placed on line 3 of the scroll window.  This would
  2657.                  cause line one to be blank.  If RTRN% = 2 on entry, LI%
  2658.                  defaults to 2 also, if LI% is set to a number higher
  2659.                  than 2.
  2660.  
  2661.               3. If all of the entries fit in the scroll window argument
  2662.                  LI% is ignored on entry.  The scroll bar will occupy
  2663.                  the line based on the value of RTRN%.  If RTRN% = 3 the
  2664.                  scroll bar will be positioned on line 3 regardless of
  2665.                  the value of LI%
  2666.  
  2667.               4. If there are more entries than interior rows in the
  2668.                  scroll window, the last "interior rows" of entries fill
  2669.                  in from the bottom of the scroll window.  For example,
  2670.                  assuming a scroll window has 10 interior rows and 20
  2671.                  entries, the 20th entry can be positioned no higher
  2672.                  than the 10th interior row, the 19th entry can be
  2673.                  positioned no higher than the ninth interior row, and
  2674.                  so on.  If one of the last "interior rows" of entries
  2675.                  is specified by argument RTRN% on entry, and LI%
  2676.                  attempts to place the entry on row higher than outlined
  2677.                  above, LI% is adjusted appropriately.
  2678.  
  2679.               On exit from routine SCRLWIND, LI% equals the interior row
  2680.               number of the scroll window that the scroll bar occupied
  2681.               prior to the exit.
  2682.  
  2683.                            FC% is used with virtual scroll windows to
  2684.               position a specified string position for the entries in
  2685.               the scroll window on the first useable column (2) of the
  2686.               scroll window.  On entry to SCRLWIND, FC% sets the string
  2687.               position for the first column of the scroll window.  On
  2688.               exit FC% points to the string position occupying column
  2689.               two.  FC% IS ONLY APPLICABLE TO VIRTUAL SCROLL WINDOWS.
  2690.               FC% has one purpose.  It allows re-entry into a virtual
  2691.               scroll window exactly as it was displayed on exit if used
  2692.               with arguments RTRN% and LI% on re-entry.  Set this
  2693.               argument to one if it is not required.
  2694.  
  2695.               EXAMPLE:  On entry FC% = 5 and LIST$(1) ="12345678901234".
  2696.                         "5678901234" will be displayed in a virtual
  2697.                         scroll window.   The first displayed character
  2698.                         in LIST$(1) will be "5".
  2699.  
  2700.  
  2701.  
  2702.                                        37
  2703.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  2704.  
  2705.  
  2706.  
  2707.  
  2708.  
  2709.  
  2710.  
  2711.  
  2712.  
  2713.                            RKEY% represents the key or action used to
  2714.               exit SCRLWIND.
  2715.  
  2716.               RKEY% may equal any of the following.
  2717.  
  2718.               RKEY%          EXIT KEY/ACTION         KIND$
  2719.  
  2720.               ** 1 to 10     F1 to F10               ALL
  2721.  
  2722.               ** 11          PAGE UP                 ALL ( *EXTENDABLE )
  2723.               ** 12          PAGE DOWN               ALL ( *EXTENDABLE )
  2724.  
  2725.                  13          ENTER ( RETURN ) or     ALL
  2726.                  13          AUTO-EXIT FEATURE.
  2727.               ** 13          MOUSE SELECTION ( Single
  2728.                              or double click )       ALL
  2729.  
  2730.                              < OK > SELECTED         ALL ( > 0 BUTTONS )
  2731.  
  2732.               ** 14          SHIFT TAB               ALL
  2733.               ** 14          LEFT ARROW              ALL ( NON-VIRTUAL )
  2734.  
  2735.               ** 15          TAB                     ALL
  2736.               ** 15          RIGHT ARROW             ALL ( NON-VIRTUAL )
  2737.  
  2738.               ** 16          UP ARROW/MOUSE          ALL (**EXTENDABLE )
  2739.               ** 19          DOWN ARROW/MOUSE        ALL (**EXTENDABLE )
  2740.  
  2741.                  27          ESC                     ALL
  2742.                              < CANCEL > SELECTED     ALL ( 2 BUTTONS )
  2743.  
  2744.               ** 30          HOME                    ALL (**EXTENDABLE )
  2745.               ** 35          END                     ALL (**EXTENDABLE )
  2746.               ** 40          INSERT                  ALL
  2747.               ** 45          DELETE                  ALL
  2748.  
  2749.               ** 50          MARK an entry           "M" (**EXTENDABLE )
  2750.               ** 55          UN-MARK an entry        "M" (**EXTENDABLE )
  2751.  
  2752.               ** 200         Mouse pressed outside   ALL ( NO BUTTONS )
  2753.                              of scroll window.
  2754.  
  2755.               ** Requires calling routine B4SCRL prior to calling
  2756.                  routine SCRLWIND.  ( SEE ROUTINE B4SCRL ).
  2757.  
  2758.                            KEYATTR% is the color of the key character
  2759.               for each item in the scroll window.  If KEYATTR% = 0
  2760.               the key character will be the same color as the other
  2761.               characters for each window item.  This would be
  2762.               appropriate if the first character in each item is ALWAYS
  2763.               the key character.  KEYATTR% MUST EQUAL ZERO FOR A SCROLL
  2764.               WINDOW TO BE A VIRTUAL SCROLL WINDOW.  IF KEYATTR% = 0 THE
  2765.  
  2766.  
  2767.  
  2768.                                        38
  2769.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  2770.  
  2771.  
  2772.  
  2773.  
  2774.  
  2775.  
  2776.  
  2777.  
  2778.  
  2779.               SCROLL WINDOW IS TREATED AS A VIRTUAL SCROLL WINDOW.
  2780.               CHECKS TO DETERMINE IF THE ELEMENTS OF LIST$() ARE TOO
  2781.               LONG TO FIT IN THE WINDOW ARE NOT MADE.  Setting KEYATTR%
  2782.               to a different color, or high intensity, allows users to
  2783.               distinguish the character as the key character for each
  2784.               item in the list.  KEYATTR% has no effect on the
  2785.               background color of an item when it is covered by the
  2786.               scroll bar.  It can effect the background color for the
  2787.               key character.  This is useful for computers without high
  2788.               intensity or color capabilities.  IF KEYATTR% <> 0 AND ANY
  2789.               SELECTION IN THE LIST WILL NOT FIT IN THE SCROLL WINDOW
  2790.               ALLOWING A LEADING AND TRAILING SPACE AN ERROR WILL BE
  2791.               REPORTED.   SCROLL WINDOWS WITH BUTTONS ARE, IN EFFECT,
  2792.               REDUCED IN WIDTH BY SIX SPACES.  THEREFORE, IF KEYATTR% <>
  2793.               0 THE SCROLL WINDOW MAY NOT BE A VIRTUAL SCROLL WINDOW.
  2794.  
  2795.                            SCROLLBAR% determines if scroll bars on the
  2796.               right and bottom border are displayed.  Pressing the mouse
  2797.               on a scroll bar arrow simulates pressing the corresponding
  2798.               arrow key.  If SCROLLBAR% > 0 the scroll bars will be
  2799.               displayed with the following exceptions.
  2800.  
  2801.               1. If the scroll window has less than 3 interior rows the
  2802.                  vertical scroll bar is not displayed.  The scroll
  2803.                  arrows will, however, be displayed on scroll windows
  2804.                  with two interior rows.
  2805.  
  2806.               2. If the scroll window is made an "EXTENDABLE" scroll
  2807.                  window by a previous call to routine B4SCRL the
  2808.                  vertical bar is not appropriate and not displayed.
  2809.  
  2810.               3. If the scroll window is NOT a virtual scroll window the
  2811.                  horizontal scroll bar is not necessary and is not
  2812.                  displayed.
  2813.  
  2814.                            BUT% allows < OK > and < CANCEL > buttons for
  2815.               the scroll window.  Buttons are selected by moving the
  2816.               cursor to the button using the tab or shift tab keys. If
  2817.               ENTER or the SPACE BAR is pressed and the cursor is on a
  2818.               button , the button is selected.  If the mouse is released
  2819.               with the mouse cursor over a button, the button is
  2820.               selected.  If BUT% = 1 the < OK > button is displayed.  If
  2821.               BUT% = 2 the < OK > and < CANCEL > buttons are displayed.
  2822.               Selecting the < OK > button simulates pressing the ENTER
  2823.               key on a selection (RKEY% = 13).  Selecting the < CANCEL >
  2824.               button simulates pressing ESC (RKEY% = 27).  IF BUT% = 1
  2825.               the ESC key will not exit unless an "E" is included in
  2826.               routine B4SCRL's argument EXIT$.  Using buttons reduces
  2827.               the interior rows of the scroll window by four and the
  2828.               interior width of the scroll window by six.  This is
  2829.               required to "make room" for the buttons.
  2830.  
  2831.  
  2832.  
  2833.  
  2834.                                        39
  2835.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  2836.  
  2837.  
  2838.  
  2839.  
  2840.  
  2841.  
  2842.  
  2843.  
  2844.  
  2845.               NOTE: ALTHOUGH BUTTONS ARE ALLOWED WITH "EXTENDABLE" ( SEE
  2846.               ROUTINE B4SCRL ) SCROLL WINDOWS, PERFORMANCE ( ESPECIALLY
  2847.               IN 286 OR SLOWER PROCESSORS) IS SACRIFICED.  IT IS
  2848.               SUGGESTED EXTENDABLE SCROLL WINDOWS ARE USED WITHOUT
  2849.               BUTTONS.  IF BUTTONS ARE REQUIRED SPEED CAN BE ENHANCED BY
  2850.               USING FUNCTION CHOICEBAR, FOR THE BUTTONS, WITH ROUTINE
  2851.               SCRLWIND, TO OBTAIN THE BUTTON EFFECT.  THIS WILL REQUIRE
  2852.               USING A "T" IN ROUTINE B4SCRL'S ARGUMENT EXIT$ TO ALLOW
  2853.               THE TAB AND SHIFT/TAB KEYS TO EXIT FROM THE SCROLL WINDOW
  2854.               AND ENTER FUNCTION CHOICBAR.  IT WILL ALSO REQUIRE AN "O"
  2855.               IN ROUTINE B4SCRL'S ARGUMENT EXIT$.  THIS WILL EXIT
  2856.               ROUTINE SCRLWIND IF THE MOUSE IS PRESSED OUTSIDE OF SAME.
  2857.               A CHECK CAN BE MADE WHEN THE MOUSE IS PRESSED OUTSIDE OF
  2858.               THE SCROLL WINDOW TO DETERMINE IF IT IS PRESSED ON A
  2859.               CHOICEBAR BUTTON.  SEE THE SAMPLE FILE SCRLRAND.BAS.
  2860.  
  2861.  
  2862.               -------------------------------------------------------
  2863.               'EXAMPLE OF A CALL TO SCRLWIND - AUTO EXIT SCROLL WINDOW
  2864.  
  2865.               DIM LIST$(11), INFO$(11)
  2866.               FOR X% = 1 TO 11              'ALWAYS START WITH 1.
  2867.                  READ LIST$(X%)
  2868.                  READ INFO$(X%)             'ONLY INCLUDE IF INFO-LINE
  2869.               NEXT                          'IS USED.
  2870.  
  2871.  
  2872.               CALL MAKEWIND(15, "", 1, 1, 20, 17, 112, 2)
  2873.               KIND$ = "A" : RTRN% = 3: KEYATTR% = 116: LI%=1: FC%=1
  2874.               CALL SCRLWIND (LIST$(), INFO$(), "", 11, KIND$, RTRN%, LI%,
  2875.                              FC%, RKEY%, 116, 1, 1)
  2876.  
  2877.               ' THE ABOVE CALL TO SCRLWIND MUST BE TYPED ON ONE LINE IN
  2878.               ' QB/QBX.
  2879.  
  2880.               DATA ONE                          : 'LIST$(1)
  2881.               DATA INFO-LINE FOR ONE            : 'INFO$(1)
  2882.               DATA TW@O                         : 'LIST$(2)
  2883.               ' FOR ABOVE KEY CHAR. = "W"
  2884.               DATA INFO-LINE FOR TWO            : 'INFO$(2)
  2885.               DATA TH@REE
  2886.               ' FOR ABOVE KEY CHAR. = "H"
  2887.               DATA INFO-LINE FOR THREE
  2888.               DATA FOUR
  2889.               DATA INFO-LINE FOR FOUR
  2890.               DATA FIV@E
  2891.               ' FOR ABOVE KEY CHAR. = "V"
  2892.               DATA INFO-LINE FOR FIVE
  2893.               DATA "-"                         : 'LIST$(5)
  2894.               ' ABOVE DATA STATEMENT PUTS A SEGMENTING LINE IN ROW 6
  2895.               DATA ""
  2896.               : 'NULL IN INFO$(5)
  2897.  
  2898.  
  2899.  
  2900.                                        40
  2901.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  2902.  
  2903.  
  2904.  
  2905.  
  2906.  
  2907.  
  2908.  
  2909.  
  2910.  
  2911.               DATA SIX@
  2912.               ' FOR ABOVE KEY CHAR. = "X"
  2913.               DATA INFO-LINE FOR SIX
  2914.               DATA SEVEN
  2915.               DATA INFO-LINE FOR SEVEN
  2916.               DATA EIGHT
  2917.               DATA INFO-LINE FOR EIGHT
  2918.               DATA NINE
  2919.               DATA INFO-LINE FOR NINE
  2920.               DATA TEN                         : 'LIST$(11)
  2921.               DATA INFO-LINE FOR TEN           : 'INFO$(11)
  2922.               -------------------------------------------------------
  2923.               The scroll window is the window defined by the call to
  2924.               MAKEWIND as it is the active window when SCRLWIND is
  2925.               called.  The entries in the scroll window and the text for
  2926.               the info-line are the items in the data statements, as
  2927.               they are read into LIST$() and INFO$(). The fourth
  2928.               parameter in the call to SCRLWIND is the number of items
  2929.               in the list ( 11 ).  As KIND$ ="A" before calling
  2930.               SCRLWIND, the scroll window is an "AUTO-EXIT SCROLL"
  2931.               window.  Since RTRN% = 3 when entering SCRLWIND the scroll
  2932.               bar will start over the third item ( THREE ).  The sixth
  2933.               DATA item for LIST$() loads LIST$(6) with "-".  Therefore,
  2934.               a line will print in row six of the scroll window.  The
  2935.               key character for each item will be red (KEYATTR% = 116 ).
  2936.               RTRN% will equal the selected item, and RKEY% will
  2937.               represent the exit key when SCRLWIND is exited.  As
  2938.               reading the data takes time, quicker scroll windows will
  2939.               be generated if all arrays used in scroll windows are
  2940.               filled using READ and DATA statement during program
  2941.               initialization.
  2942.  
  2943.  
  2944.  
  2945.          3.01 B4SCRL ( EXIT$, MARK$, TAGCOL%, NOREFRESH% )
  2946.  
  2947.               Description: Sets the "exit keys" or "exit circumstances",
  2948.               the marked ( tagged ) selections on entry, and
  2949.               marked selection arrow color for subsequent call to
  2950.               SCRLWIND.  May also be used to suppress the "refreshing"
  2951.               of a scroll window on entry.
  2952.  
  2953.               NOTE1: IT IS NOT NECESSARY TO CALL B4SCRL PRIOR TO CALLING
  2954.               SCRLWIND UNLESS ONE OF B4SCRL'S FEATURES ARE REQUIRED.
  2955.  
  2956.               NOTE2: B4SCRL ONLY AFFECTS THE NEXT CALL TO SCRLWIND FOR
  2957.               ALL ARGUMENTS.  THEREFORE, IF B4SCRL IS REQUIRED FOR A
  2958.               PARTICULAR SCROLL WINDOW IT MUST ALWAYS BE CALLED PRIOR TO
  2959.               CALLING SCRLWIND FOR THAT SCROLL WINDOW.
  2960.               ALWAYS PLACE A CALL TO B4SCRL, IF IT IS REQUIRED,
  2961.               IMMEDIATELY BEFORE THE CALL TO SCRLWIND.
  2962.  
  2963.  
  2964.  
  2965.  
  2966.                                        41
  2967.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  2968.  
  2969.  
  2970.  
  2971.  
  2972.  
  2973.  
  2974.  
  2975.  
  2976.  
  2977.               EXAMPLE: CALL B4SCRL (......   ' IF B4SCRL IS REQUIRED
  2978.                        CALL SCRLWIND (.....  ' IT MUST PRECEDE SCRLWIND.
  2979.                        CALL SCRLWIND (.......' THE PREVIOUS CALL TO
  2980.                                              ' B4SCRL DOES NOT AFFECT
  2981.                                              ' THIS CALL TO SCRLWIND.
  2982.  
  2983.               Arguments:   EXIT$ sets the exit keys or exit
  2984.               circumstances for a subsequent call to SCRLWIND.
  2985.               Normally SCRLWIND exits via the ESC or ENTER keys.  There
  2986.               is no need to use B4SCRL to provide alternate means to
  2987.               exit unless the scroll window requires same.  EXIT$ may be
  2988.               any combination of the following.
  2989.  
  2990.                 "E"         The ESC key will exit SCRLWIND.
  2991.                 "R"         The ENTER (RETURN) key will exit SCRLWIND.
  2992.  
  2993.                 "0"         The F10 key will exit SCRLWIND.
  2994.                 "1" to "9"  The F1 to F9 keys will exit SCRLWIND.
  2995.  
  2996.                 "I"         The INSERT key will exit SCRLWIND.
  2997.                 "D"         The DELETE key will exit SCRLWIND.
  2998.  
  2999.                 "T"         TAB and SHIFT/TAB keys will exit SCRLWIND
  3000.                             provided the scroll window has no buttons.
  3001.  
  3002.                 "A"         RIGHT ARROW and LEFT ARROW keys will exit
  3003.                             SCRLWIND. SCRLWIND must be NON-VIRTUAL.
  3004.  
  3005.                 "M"         The mouse will exit SCRLWIND if it is
  3006.                             RELEASED with the cursor on a valid
  3007.                             selection. ( Single click )
  3008.  
  3009.                 "MC"        Double clicking the mouse on a selection
  3010.                             will exit.
  3011.  
  3012.                 "O"         The mouse will exit SCRLWIND if it is
  3013.                             pressed outside of the scroll window AND the
  3014.                             scroll window has no buttons.
  3015.  
  3016.                 "X"         This makes the scroll window an "EXTENDABLE"
  3017.                             scroll window.  Any attempt to scroll past
  3018.                             the last entry ( PAGE DOWN, DOWN ARROW OR
  3019.                             MOUSE ) in the scroll window or scroll
  3020.                             before the first entry ( PAGE UP, UP ARROW
  3021.                             OR MOUSE ) in the scroll window will exit
  3022.                             SCRLWIND.  The HOME or END keys exit
  3023.                             SCRLWIND.  If the scroll window is a
  3024.                             multiple mark scroll window ( argument KIND$
  3025.                             for routine SCRLWIND equals "M" ) any change
  3026.                             in mark status of an entry will exit
  3027.                             SCRLWIND.  ( FURTHER EXPLANATION AND
  3028.                             RESTRICTIONS FOLLOW.  )
  3029.  
  3030.  
  3031.  
  3032.                                        42
  3033.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  3034.  
  3035.  
  3036.  
  3037.  
  3038.  
  3039.  
  3040.  
  3041.  
  3042.  
  3043.               EXAMPLE: EXIT$ = "12DR"  The F1, F2, DELETE, and ENTER
  3044.                                        keys exit routine SCRLWIND.
  3045.  
  3046.               NOTE1:  IF EXIT$ CONTAINS AN "X" THE SCROLL WINDOW IS AN
  3047.               "EXTENDABLE" SCROLL WINDOW.  ALL ENTRIES MUST FIT IN THE
  3048.               SCROLL WINDOW OR AN ERROR WILL BE REPORTED.  IF THERE ARE
  3049.               10 INTERIOR ROWS IN THE SCROLL WINDOW THE NUMBER OF
  3050.               ENTRIES ( ARGUMENT ENTRIES% FOR ROUTINE SCRLWIND ) MUST BE
  3051.               EQUAL TO, OR LESS THAN, 10.
  3052.  
  3053.               NOTE2:  IF THE INSERT OR DELETE KEYS ARE USED AS EXIT KEYS
  3054.               AND THE SCROLL WINDOW IS A MULTIPLE MARK, EXTENDABLE,
  3055.               SCROLL WINDOW THE INSERT AND DELETE KEYS WILL NO LONGER
  3056.               MARK AND UN-MARK ENTRIES.  THE "+" AND "-" KEYS WILL STILL
  3057.               MARK AND UN-MARK ENTRIES, HOWEVER.
  3058.  
  3059.               Placing an "X" in EXIT$ makes the scroll window an
  3060.               "EXTENDABLE" scroll window.  This provides the ability to
  3061.               scroll through records in large random access, binary,
  3062.               ISAM, BTRIEVE, or many other data files.  On entry to
  3063.               SCRLWIND memory constraints may prohibit placing all
  3064.               records in a database in a scroll window.  With
  3065.               "EXTENDABLE" scroll windows, the first 15 records of a
  3066.               data file may be placed in a scroll window with 15
  3067.               interior rows.
  3068.  
  3069.               NOTE:  THE NUMBER OF INTERIOR ROWS IN A SCROLL WINDOW IS
  3070.               EQUAL TO THE NUMBER OF ROWS IN THE WINDOW ( AS SET BY THE
  3071.               CALL TO MAKEWIND FOR THE SCROLL WINDOW ) MINUS 2 IF THE
  3072.               CALL TO MAKEWIND DID NOT SPECIFY A TITLE BOX.  IF THE CALL
  3073.               TO MAKEWIND SPECIFIED A TITLE BOX THE NUMBER OF INTERIOR
  3074.               ROWS EQUALS THE ROWS SET BY THE CALL TO MAKEWIND MINUS 4.
  3075.               IF BUTTONS ARE USED THE NUMBER OF INTERIOR ROWS IS REDUCED
  3076.               BY AN ADDITIONAL 4 ROWS.  USING BUTTONS IN "EXTENDABLE"
  3077.               SCROLL WINDOWS IS NOT RECOMMENDED AS A NOTICEABLE ( ESP-
  3078.               ECIALLY ON 286 OR SLOWER MICROPROCESSORS ) DEGRADATION
  3079.               WILL BE OBVIOUS.
  3080.  
  3081.               An attempt to scroll past the 15th record in the scroll
  3082.               window or before the first record in the scroll window
  3083.               causes SCRLWIND to be exited.  Argument RKEY% ( from
  3084.               routine SCRLWIND ) can be used to determine the key or
  3085.               circumstance which caused the exit.  The following lists
  3086.               the values returned by SCRLWIND's argument RKEY% which are
  3087.               unique to "EXTENDABLE" scroll windows.
  3088.  
  3089.               - RKEY% = 19 -- The DOWN ARROW was pressed or the MOUSE
  3090.                 was pressed on the windows bottom border ( SEE FOLLOWING
  3091.                 NOTE ) with the scroll bar on the last entry in the
  3092.                 scroll window.  An attempt is being made to access the
  3093.                 next record ( relative to the last record in the scroll
  3094.                 window ) in the data file.  On exit, a check should be
  3095.  
  3096.  
  3097.  
  3098.                                        43
  3099.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  3100.  
  3101.  
  3102.  
  3103.  
  3104.  
  3105.  
  3106.  
  3107.  
  3108.  
  3109.                 made to determine if the last record in the scroll
  3110.                 window is not the last record in the data file.  If it
  3111.                 is not, all records in SCRLWIND's arguments LIST$()
  3112.                 should be shifted to the preceding element of LIST$().
  3113.                 The last element of LIST$() should be filled with the
  3114.                 next record.
  3115.  
  3116.                     ( FILEPOINTER MUST = LAST RECORD IN SCROLL WINDOW )
  3117.                     ( MAX = NUMBER OF RECORDS IN FILE )
  3118.                     ( ENTRIES% = NUMBER OF ENTRIES IN THE WINDOW )
  3119.  
  3120.                     IF FILEPOINTER < MAX THEN
  3121.                       FILEPOINTER = FILEPOINTER + 1
  3122.                       FOR X% = 1 TO ENTRIES% - 1
  3123.                          SWAP LIST$(X%), LIST$(X% + 1)
  3124.                       NEXT
  3125.                       ' DO WHAT YOUR DATABASE REQUIRES GET A RECORD AT
  3126.                       ' POSITION FILEPOINTER.
  3127.                       LIST$(ENTRIES%) = THE RECORD
  3128.                     END IF
  3129.  
  3130.                 The scroll window should then be re-entered.
  3131.                 FILEPOINTER POINTS TO THE LAST RECORD IN THE SCROLL
  3132.                 WINDOW.
  3133.  
  3134.               NOTE: RKEY% MAY ALSO EQUAL 19 IF THE SCROLL WINDOW IS A
  3135.               MULTIPLE MARK, EXTENDABLE, SCROLL WINDOW AND A MARK KEY
  3136.               ( INS, DEL, +, or - ) IS PRESSED WITH THE SCROLL BAR ON
  3137.               THE LAST ENTRY.  IF THE ENTRY DOES NOT CHANGE "MARK"
  3138.               STATUS RKEY% WILL EQUAL 19 EMULATING THE DOWN ARROW KEY.
  3139.               IF THE ENTRY CHANGES "MARK" STATUS RKEY% WILL EQUAL 50 OR
  3140.               55.  SEE DESCRIPTIONS FOR RKEY% = 50 AND RKEY% = 55 TO SEE
  3141.               HOW TO MOVE TO THE NEXT RECORD WHEN RKEY% = 50 OR RKEY% =
  3142.               55.
  3143.  
  3144.               - RKEY% = 16 -- The UP ARROW was pressed or the MOUSE was
  3145.                 pressed on the top border with the scroll bar on the
  3146.                 first entry in the scroll window.  An attempt is being
  3147.                 made to access the preceding record ( relative to the
  3148.                 first record in the scroll window ) in the data file.
  3149.                 On exit, a check should be made to determine if the
  3150.                 first record in the scroll window is not the first
  3151.                 record in the data file.  If it is not, all records in
  3152.                 SCRLWIND's arguments LIST$() should be shifted to the
  3153.                 next element of LIST$().
  3154.  
  3155.                     ( FILEPOINTER MUST = FIRST RECORD IN SCROLL WINDOW )
  3156.                     ( MAX = NUMBER OF RECORDS IN FILE )
  3157.                     ( ENTRIES% = NUMBER OF ENTRIES IN THE WINDOW )
  3158.  
  3159.                     IF FILEPOINTER > 1 THEN
  3160.                       FILEPOINTER = FILEPOINTER - 1
  3161.  
  3162.  
  3163.  
  3164.                                        44
  3165.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  3166.  
  3167.  
  3168.  
  3169.  
  3170.  
  3171.  
  3172.  
  3173.  
  3174.  
  3175.                       FOR X% = ENTRIES% TO 2 STEP - 1
  3176.                         SWAP LIST$(X%), LIST$(X% - 1)
  3177.                       NEXT
  3178.                      ' DO WHAT YOUR DATABASE REQUIRES GET A RECORD AT
  3179.                      ' POSITION FILEPOINTER .
  3180.                       LIST$(1) = THE RECORD
  3181.                     END IF
  3182.  
  3183.                 The scroll window should then be re-entered.
  3184.                 FILEPOINTER POINTS TO THE FIRST ENTRY IN THE SCROLL
  3185.                 WINDOW.
  3186.  
  3187.               - RKEY% = 11 -- The PAGE UP key was pressed.  A check
  3188.                 should be made to determine if the are enough preceding
  3189.                 records in the data file to update LIST$(1) to
  3190.                 LIST$( INTERIOR ROWS IN THE SCROLL WINDOW ) with
  3191.                 preceding records ( relative to the first record in the
  3192.                 scroll window).  If there are, LIST$() should be
  3193.                 refreshed with those records.
  3194.  
  3195.                     ( FILEPOINTER MUST = FIRST RECORD IN SCROLL WINDOW )
  3196.                     ( ROWS% = INTERIOR ROWS IN SCROLL WINDOW )
  3197.                     ( MAX = NUMBER OF RECORDS IN FILE )
  3198.  
  3199.                     ENTRIES% WILL BE USED BY THE NEXT CALL TO SCRLWIND
  3200.                     TO SET THE NUMBER OF ENTRIES IN THE SCROLL WINDOW.
  3201.  
  3202.                     RTRN% WILL BE DETERMINE WHICH ENTRY WILL BE
  3203.                     HIGHLIGHTED ON THE NEXT CALL TO SCRLWIND.
  3204.  
  3205.                     FILEPOINTER = FILEPOINTER - ROWS%
  3206.  
  3207.                     ( If there are not enough preceding records in the
  3208.                     scroll window FILEPOINTER should be set to the first
  3209.                     record. )
  3210.  
  3211.                     IF FILEPOINTER < 1 THEN FILEPOINTER = 1
  3212.  
  3213.                     ENTRIES% = 0
  3214.                     WHILE ENTRIES% < ROWS% AND ENTRIES% < MAX
  3215.                       ENTRIES%=ENTRIES% + 1
  3216.                       ' DO WHAT YOUR DATABASE REQUIRES GET A RECORD AT
  3217.                       ' POSITION FILEPOINTER .
  3218.                       LIST%(ENTRIES%)= THE RECORD
  3219.                       FILEPOINTER = FILEPOINTER + 1
  3220.                     WEND
  3221.                     FILEPOINTER = FILEPOINTER - 1
  3222.                     RTRN% = 1     ' HIGHLIGHT FIRST SCROLL WINDOW ENTRY.
  3223.  
  3224.                 The scroll window should then be re-entered.
  3225.                 FILEPOINTER POINTS TO THE LAST ENTRY IN THE SCROLL
  3226.                 WINDOW.
  3227.  
  3228.  
  3229.  
  3230.                                        45
  3231.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  3232.  
  3233.  
  3234.  
  3235.  
  3236.  
  3237.  
  3238.  
  3239.  
  3240.  
  3241.               - RKEY% = 12 -- The PAGE DOWN key was pressed.  A check
  3242.                 should be made to determine if the are enough records
  3243.                 ( relative to the last record in the scroll window ) in
  3244.                 the data file to update LIST$(1) to LIST$( INTERIOR ROWS
  3245.                 IN THE SCROLL WINDOW ) with new records ( relative to
  3246.                 the last record in the scroll window ). If there are,
  3247.                 LIST$() should be refreshed with these records.
  3248.  
  3249.                     ( FILEPOINTER MUST = LAST RECORD IN SCROLL WINDOW )
  3250.                     ( ROWS% = INTERIOR ROWS IN SCROLL WINDOW )
  3251.                     ( MAX = NUMBER OF RECORDS IN FILE )
  3252.  
  3253.                     ENTRIES% WILL BE USED BY THE NEXT CALL TO SCRLWIND
  3254.                     TO SET THE NUMBER OF ENTRIES IN THE SCROLL WINDOW.
  3255.  
  3256.                     RTRN% WILL BE DETERMINE WHICH ENTRY WILL BE
  3257.                     HIGHLIGHTED ON THE NEXT CALL TO SCRLWIND.
  3258.  
  3259.                     IF FILEPOINTER + ROWS > MAX THEN
  3260.                       FILEPOINTER = ( MAX - ROWS% + 1 )
  3261.                       IF FILEPOINTER < 1 THEN FILEPOINTER = 1
  3262.                     ELSE
  3263.                       FILEPOINTER = FILEPOINTER + 1
  3264.                     END IF
  3265.  
  3266.                     ENTRIES% = 0
  3267.                     WHILE ENTRIES% < ROWS% AND ENTRIES% < MAX
  3268.                      ENTRIES%=ENTRIES% + 1
  3269.                      ' DO WHAT YOUR DATABASE REQUIRES GET A RECORD AT
  3270.                      ' POSITION FILEPOINTER.
  3271.                      LIST%(ENTRIES%) = THE RECORD
  3272.                      FILEPOINTER = FILEPOINTER + 1
  3273.                     WEND
  3274.                     FILEPOINTER = FILEPOINTER - 1
  3275.                     RTRN% = ENTRIES%
  3276.  
  3277.                 The scroll window should then be re-entered.
  3278.                 FILEPOINTER POINTS TO THE LAST ENTRY IN THE SCROLL
  3279.                 WINDOW.
  3280.  
  3281.               - RKEY% = 30 -- The HOME key was pressed.  The scroll
  3282.                 window should be filled with the first records in the
  3283.                 data file.
  3284.  
  3285.                     ( FILEPOINTER MUST = FIRST RECORD IN THE DATA FILE )
  3286.                     ( ROWS% = INTERIOR ROWS IN SCROLL WINDOW )
  3287.                     ( MAX = NUMBER OF RECORDS IN FILE )
  3288.  
  3289.                     ENTRIES% WILL BE USED BY THE NEXT CALL TO SCRLWIND
  3290.                     TO SET THE NUMBER OF ENTRIES IN THE SCROLL WINDOW.
  3291.  
  3292.                     RTRN% WILL BE DETERMINE WHICH ENTRY WILL BE
  3293.  
  3294.  
  3295.  
  3296.                                        46
  3297.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  3298.  
  3299.  
  3300.  
  3301.  
  3302.  
  3303.  
  3304.  
  3305.  
  3306.  
  3307.                     HIGHLIGHTED ON THE NEXT CALL TO SCRLWIND.
  3308.  
  3309.                     FILEPOINTER = 1
  3310.                     ENTRIES% = 0
  3311.                     WHILE ENTRIES% < ROWS% AND ENTRIES% < MAX
  3312.                      ENTRIES%=ENTRIES% + 1
  3313.                      ' DO WHAT YOUR DATABASE REQUIRES GET A RECORD AT
  3314.                      ' POSITION FILEPOINTER .
  3315.                      LIST%(ENTRIES%)=RECORD
  3316.                      FILEPOINTER = FILEPOINTER + 1
  3317.                     WEND
  3318.                     FILEPOINTER = FILEPOINTER - 1
  3319.                     RTRN% = 1    ' HIGHLIGHT FIRST SCROLL WINDOW ENTRY.
  3320.  
  3321.                 The scroll window should then be re-entered.
  3322.                 FILEPOINTER POINTS TO THE LAST RECORD IN THE SCROLL
  3323.                 WINDOW.
  3324.  
  3325.               - RKEY% = 35 -- The END key was pressed.  The scroll
  3326.                 window should be filled with the last records in the
  3327.                 data file.
  3328.  
  3329.                     ( FILEPOINTER MUST BE SET TO THE CORRECT RECORD )
  3330.                     ( ROWS% = INTERIOR ROWS IN SCROLL WINDOW )
  3331.                     ( MAX = NUMBER OF RECORDS IN FILE )
  3332.  
  3333.                     ENTRIES% WILL BE USED BY THE NEXT CALL TO SCRLWIND
  3334.                     TO SET THE NUMBER OF ENTRIES IN THE SCROLL WINDOW.
  3335.  
  3336.                     RTRN% WILL BE DETERMINE WHICH ENTRY WILL BE
  3337.                     HIGHLIGHTED ON THE NEXT CALL TO SCRLWIND.
  3338.  
  3339.                     FILEPOINTER = MAX - ROWS% + 1
  3340.                     IF FILEPOINTER < 1 THEN FILEPOINTER = 1
  3341.  
  3342.                     ENTRIES% = 0
  3343.                     WHILE ENTRIES% < ROWS% AND ENTRIES% < MAX
  3344.                      ENTRIES%=ENTRIES% + 1
  3345.                      ' DO WHAT YOUR DATABASE REQUIRES GET A RECORD AT
  3346.                      ' POSITION FILEPOINTER .
  3347.                      LIST%(ENTRIES%)=RECORD#
  3348.                      FILEPOINTER = FILEPOINTER + 1
  3349.                     WEND
  3350.                     FILEPOINTER = FILEPOINTER - 1
  3351.                     RTRN% = ENTRIES%   ' HIGHLIGHT LAST ENTRY.
  3352.  
  3353.                 The scroll window should then be re-entered.
  3354.                 FILEPOINTER POINTS TO THE LAST RECORD IN THE SCROLL
  3355.                 WINDOW AND IN THE DATA FILE.
  3356.  
  3357.               - RKEY% = 50 -- The scroll window is a "MARK", extendable,
  3358.                 scroll window.  An un-marked entry was marked.  ( SEE
  3359.  
  3360.  
  3361.  
  3362.                                        47
  3363.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  3364.  
  3365.  
  3366.  
  3367.  
  3368.  
  3369.  
  3370.  
  3371.  
  3372.  
  3373.                 DESCRIPTION FOR ARGUMENT MARK$ FOR THIS ROUTINE ).  To
  3374.                 determine which record was marked;
  3375.  
  3376.                     ( FILEPOINTER MUST = FIRST RECORD IN SCROLL WINDOW )
  3377.                     ( RTRN% IS RETURNED BY ROUTINE SCRLWIND. IT
  3378.                       POINTS TO THE "MARKED" ENTRY )
  3379.  
  3380.                     ' DO WHAT YOUR DATABASE REQUIRES GET A RECORD AT
  3381.                     ' POSITION FILEPOINTER + RTRN% - 1.
  3382.  
  3383.                     ' UPDATE THE RECORD TO SHOW IT IS MARKED.
  3384.  
  3385.                     RTRN% = RTRN% + 1     ' MOVE TO THE NEXT ENTRY
  3386.  
  3387.                     IF RTRN% > ENTRIES% -- GO TO THE ROUTINE USED FOR
  3388.                                            THE DOWN ARROW ( RKEY% = 16 )
  3389.  
  3390.                 The scroll window should then be re-entered.
  3391.                 FILEPOINTER POINTS TO THE FIRST RECORD IN THE SCROLL
  3392.                 WINDOW.
  3393.  
  3394.               - RKEY% = 55 -- The scroll window is a "MARK" ( and
  3395.                 "EXTENDABLE" ) scroll window.  An marked entry was un-
  3396.                 marked.  ( SEE DESCRIPTION FOR ARGUMENT MARK$ FOR THIS
  3397.                 ROUTINE).  To determine which record was marked;
  3398.  
  3399.                     ( FILEPOINTER MUST = FIRST RECORD IN SCROLL WINDOW )
  3400.                     ( RTRN% IS RETURNED BY ROUTINE SCRLWIND. IT
  3401.                       POINTS TO THE "MARKED" ENTRY )
  3402.  
  3403.                     ' DO WHAT YOUR DATABASE REQUIRES GET A RECORD AT
  3404.                     ' POSITION FILEPOINTER + RTRN% - 1.
  3405.  
  3406.                     ' UPDATE THE RECORD TO SHOW IT IS NOT MARKED.
  3407.  
  3408.                     RTRN% = RTRN% + 1     ' MOVE TO THE NEXT ENTRY
  3409.  
  3410.                     IF RTRN% > ENTRIES% -- GO TO THE ROUTINE USED FOR
  3411.                                            THE DOWN ARROW ( RKEY% = 16 )
  3412.  
  3413.                 The scroll window should then be re-entered.
  3414.                 FILEPOINTER POINTS TO THE FIRST RECORD IN THE SCROLL
  3415.                 WINDOW.
  3416.  
  3417.                 NOTE: "EXTENDABLE" SCROLL WINDOWS ONLY EXIT WITH RKEY%
  3418.                 EQUAL TO 50 OR RKEY% EQUAL TO 55 IF A CHANGE IN "MARK"
  3419.                 STATUS FOR AN ENTRY OCCURS.  AN ATTEMPT TO MARK A
  3420.                 PREVIOUSLY MARKED ENTRY OR UN-MARK A PREVIOUSLY UN-
  3421.                 MARKED ENTRY WILL NOT EXIT ROUTINE SCRLWIND.
  3422.  
  3423.               - RKEY% = 1 TO 10, 13-15, 27, 40, 45, or 200  -- These
  3424.               values for RKEY% are not unique to an "EXTENDABLE" scroll
  3425.  
  3426.  
  3427.  
  3428.                                        48
  3429.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  3430.  
  3431.  
  3432.  
  3433.  
  3434.  
  3435.  
  3436.  
  3437.  
  3438.  
  3439.               window.  They remain available as a means to exit an
  3440.               "EXTENDABLE" scroll window, however.  SEE ARGUMENT RKEY%
  3441.               FOR ROUTINE SCRLWIND.
  3442.  
  3443.               NOTE: WHEN A SCROLL WINDOW IS AN EXTENDABLE SCROLL WINDOW
  3444.               IT'S OPTIONS ARE AFFECTED AS FOLLOWS:
  3445.  
  3446.               1. PRESSING THE FIRST LETTER OF AN ENTRY OR "KEY
  3447.                  CHARACTER" OF AN ENTRY DOES NOT MOVE THE SCROLL BAR TO
  3448.                  THE ENTRY.  AS THE SEARCH IS CONFINED TO THE ENTRIES IN
  3449.                  THE SCROLL WINDOW, AND ALL OF THE RECORDS ARE NOT IN
  3450.                  THE SCROLL WINDOW, "KEY CHARACTERS", ARE USELESS.
  3451.  
  3452.               2. AUTO-EXIT SCROLL WINDOWS ARE NOT PERMITTED ALSO, FOR
  3453.                  THE SAME REASON.  TO SEARCH FOR A RECORD, THE F1 KEY,
  3454.                  FOR EXAMPLE, CAN BE USED TO EXIT SCRLWIND AND PROMPT
  3455.                  THE USER FOR A SEARCH CRITERIA.  THE DATABASE CAN BE
  3456.                  SEARCHED, AND IF A MATCH IS FOUND, SCRLWIND MAY BE RE-
  3457.                  ENTERED DISPLAYING THE "FOUND" RECORD.
  3458.  
  3459.               3. THE OPTIONAL SCROLLBAR ON THE RIGHT BORDER OF THE
  3460.                  SCROLL WINDOW IS DISABLED FOR THE CALL TO SCRLWIND.
  3461.  
  3462.               4. THE SPACE BAR ( PRINT KEY ON SOME SYSTEMS ) DOES NOT
  3463.                  MARK/UN-UNMARK ALL ENTRIES IN MULTIPLE MARK SCROLL
  3464.                  WINDOWS.
  3465.  
  3466.                            MARK$ is a string representing those entries,
  3467.               on entering SCRLWIND, to be marked.  This is only
  3468.               appropriate if the scroll window is a multiple mark scroll
  3469.               window ( SCRLWIND's argument KIND$ = "M" ).  MARK$ must be
  3470.               the exact length as the number of entries in the scroll
  3471.               window.  IF IT IS NOT IT IS IGNORED!  On entry to routine
  3472.               SCRLWIND a space ( CHR$(32) ) in MARK$ is decoded as an
  3473.               un-marked entry.  If the first character of MARK$ = " "
  3474.               the first entry in the scroll window will not be marked.
  3475.               An arrow ( CHR$(16) ) in MARK$ is decoded as a marked
  3476.               entry.  If the second character of MARK$ = CHR$(16) the
  3477.               second entry in the scroll window is marked.  Each
  3478.               character in MARK$ represents a marked or un-marked entry
  3479.               in the scroll window.  On exit from routine SCRLWIND,
  3480.               SCRLWIND's argument KIND$ holds the string representation
  3481.               for those marked and un-marked items.  B4SCRL's argument
  3482.               MARK$ holds the string representation on entry only.  If
  3483.               the scroll window is to be re-entered it is necessary to
  3484.               refresh MARK$.  The following example demonstrates this.
  3485.  
  3486.               REENTER:
  3487.               KIND$ = "M"     ' MAKE A MULTIPLE MARK SCROLL WINDOW
  3488.               CALL B4SCRL ("", MARK$ )     ' ENTER WITH SOME ENTRIES
  3489.                                             ' MARKED.
  3490.  
  3491.  
  3492.  
  3493.  
  3494.                                        49
  3495.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  3496.  
  3497.  
  3498.  
  3499.  
  3500.  
  3501.  
  3502.  
  3503.  
  3504.  
  3505.               ' WHILE IN THE SCROLL WINDOW ENVIRONMENT THE MARKED
  3506.               ' ENTRIES MAY CHANGE.
  3507.               CALL SCRLWIND ( L$(), I$(), TL$, ENTRIES%, KIND$ ........
  3508.               ' KIND$ REPRESENTS THE MARKED ENTRIES ON EXIT
  3509.  
  3510.               MARK$ = KIND$    ' MARK$ MUST BE REFRESHED IF THE SCROLL
  3511.                                ' WINDOW IS TO BE RE-ENTERED
  3512.  
  3513.               ' KIND$ = "" IF NOTHING WAS MARKED.  IF LENGTH OF MARK$ IS
  3514.               ' NOT ENTRIES% LONG IT IS IGNORED, THEREFORE ON RE-ENTRY
  3515.               ' NO ENTRIES ARE MARKED.
  3516.  
  3517.               GOTO REENTER
  3518.  
  3519.               NOTE: IT IS THE PROGRAMMER'S RESPONSIBILITY TO ASSURE
  3520.               MARK$ CONTAINS SPACES ( " " ) AND ARROWS ( CHR$(16) )
  3521.               ONLY.  ANY OTHER CHARACTERS WILL MARK ENTRIES WITH THAT
  3522.               CHARACTER ON ENTRY ONLY.  IF THE ENTRY IS UN-MARKED AND
  3523.               RE-MARKED IN THE SCROLL WINDOW ENVIRONMENT THE NORMAL MARK
  3524.               CHARACTER IS USED.
  3525.  
  3526.                            TAGCOL% sets the color of the marked "tagged"
  3527.               selection  arrow for mark scroll windows.  If TAGCOL% = 0
  3528.               the arrow assumes the same color as the text in the scroll
  3529.               window.  TAGCOL% is adjusted to TAGCOL% AND 15 if it is
  3530.               set over 15. It only affects the arrow's foreground color.
  3531.  
  3532.                            NOREFRESH% can be used to re-enter a scroll
  3533.               window without re-printing the text in same.  It is used
  3534.               to enhance the speed on re-entry and avoid any flicker by
  3535.               needlessly re-printing the text.  If NOREFRESH% = 0 ( the
  3536.               default without calling B4SCRL ) the scroll window is
  3537.               refreshed on entry.  If NOREFRESH% = 1 the scroll window
  3538.               is not refreshed on entry.
  3539.  
  3540.               MOTE: SETTING NOREFRESH% TO ONE IS ONLY APPROPRIATE IF:
  3541.  
  3542.                     1. The scroll window is already displayed.
  3543.  
  3544.                     2. The scroll window is being re-entered in the same
  3545.                        state as it was exited.
  3546.  
  3547.          3.02 MARKED% (KIND$, START%)
  3548.  
  3549.               Description: MARKED%(KIND$, START%) is a function used
  3550.               to decode SCRLWIND's argument KIND$ after a multiple mark
  3551.               scroll window is exited.  MARKED%(KIND$, START%) will equal
  3552.               the next position in KIND$ starting from position START%
  3553.               which contains a CHR$(16).  If the third element (item)
  3554.               in LIST$() was marked in the call to SCRLWIND and START%
  3555.               =1, THEN: MARKED%(KIND$,START%) = 3.
  3556.  
  3557.  
  3558.  
  3559.  
  3560.                                        50
  3561.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  3562.  
  3563.  
  3564.  
  3565.  
  3566.  
  3567.  
  3568.  
  3569.  
  3570.  
  3571.               Arguments:   KIND$ is the string returned by calling
  3572.               SCRLWIND with the MARKED option ON. KIND$ = "" if no
  3573.               items were marked.
  3574.  
  3575.                           START% is the position in KIND$ to start
  3576.               searching for a CHR$(16).  A CHR$(16) in  KIND$
  3577.               represents a marked element in the string array LIST$()
  3578.               used in SCRLWIND. Every time a position in KIND$ is
  3579.               found which corresponds to a marked element of LIST$(),
  3580.               START% is set to a new value which is equal to the
  3581.               "marked" position in KIND$ + 1.  This is the next
  3582.               position in KIND$ where the search will start for
  3583.               another "marked" position. If MARKED% =0 there are no
  3584.               more "marked" positions in KIND$ or KIND$ = "".
  3585.               -------------------------------------------------------
  3586.               'EXAMPLE USING THE FUNCTION MARKED% (KIND$,START%) THIS
  3587.               'EXAMPLE PRINTS THE MARKED ITEMS IN LIST$() AFTER A CALL
  3588.               'TO SCRLWIND.
  3589.  
  3590.               'GIVEN: SCRLWIND HAS BEEN CALLED. THE FOURTH AND TENTH
  3591.               'ELEMENTS OF LIST$() WERE MARKED.  KIND$ WAS RETURNED BY
  3592.               'A PREVIOUS THE CALL TO SCRLWIND.
  3593.  
  3594.               DECLARE FUNCTION MARKED% (KIND$, START%) ' MUST BE IN
  3595.               '(Put this at the start of the module)   ' MODULE USING
  3596.                                                        ' FUNC. MARKED%.
  3597.  
  3598.               START%=1     ' START THE SEARCH AT POSITION 1 OF KIND$.
  3599.               DO                                   ' MARKED% = 0 AFTER
  3600.                  A% = MARKED%(KIND$, START%)       ' ALL MARKED ITEMS
  3601.                  IF A% = 0 THEN EXIT DO            ' ARE FOUND OR IF
  3602.                    PRINT LIST$(A%)
  3603.                  END IF
  3604.               LOOP
  3605.               -------------------------------------------------------
  3606.               The first time through the loop, MARKED% (KIND$, START%)
  3607.               will equal 4, and LIST$(4) will print.  START% is auto-
  3608.               matically set to 5, the next position to start searching
  3609.               KIND$ for a "marked" position in KIND$.  The second loop
  3610.               will set MARKED% (KIND$,START%) to 10 and LIST$(10) will
  3611.               print.  As there are no more marked positions, MARKED% =
  3612.               0 and the loop be exited.
  3613.  
  3614.  
  3615.  
  3616.  
  3617.  
  3618.  
  3619.  
  3620.  
  3621.  
  3622.  
  3623.  
  3624.  
  3625.  
  3626.                                        51
  3627.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  3628.  
  3629.  
  3630.  
  3631.  
  3632.  
  3633.  
  3634.  
  3635.  
  3636.  
  3637.                        ****** INPUT ROUTINES ******
  3638.  
  3639.          Input routines provide the ability to generate a single
  3640.          character input field ( GETANS ), a single input field
  3641.          ( INPTWIND ), or multiple input fields ( MULTINPT ).  Full
  3642.          editing is provided within each field.  Up to 10 multiple input
  3643.          screens may be used, with each screen capable of supporting up
  3644.          to 150 fields. Fields may be defined as numeric, alpha/numeric,
  3645.          or date.  Numeric fields may be designated 0 to 6 decimal
  3646.          places and optionally padded with leading zeros.  Numerous
  3647.          additional options are available.  Two additional input
  3648.          routines provide input in the form of displayed choices.
  3649.          Function CHOICEBAR% provides up to 10 choices displayed on
  3650.          a "choicebar".  Function CHOICEWIND% generates a text filled
  3651.          window with a choicebar in same.
  3652.  
  3653.          4.00 INPTINIT ( DATEFORMAT%, ISDOT%, AT1%, BLANK%, SND% )
  3654.               See: Example - Input window
  3655.  
  3656.               Description: Initialization routine for input routines
  3657.               INPTWIND, MULTINPT, CHOICEWIND%, and CHOICEBAR%. Function
  3658.               CHOICEBAR% is used by routine SCRLWIND for the < OK > and
  3659.               < CANCEL > buttons.  INPTINIT MUST BE CALLED ONCE IN EVERY
  3660.               PROGRAM BEFORE ANY CALLS TO THESE ROUTINES (INCLUDING
  3661.               SCRLWIND WITH BUTTONS).
  3662.  
  3663.               NOTE: IF A CLEAR STATEMENT IS EXECUTED BY THE PROGRAM
  3664.               INPUT INITIALIZATION MEMORY IS LOST.  INPTINIT MUST BE
  3665.               CALLED AFTER A CLEAR STATEMENT TO RE-INITIALIZE INPUT
  3666.               INITIALIZATION MEMORY.
  3667.  
  3668.               Arguments:   DATEFORMAT% sets the valid date format for
  3669.               input routines INPTWIND and MULTINPT.  If a field in
  3670.               either input routine is designated a date field, the field
  3671.               can not be exited if the entered date does not match the
  3672.               date format as specified by DATEFORMAT%.  The valid date
  3673.               format varies predicated on the specified field width for
  3674.               the date field.  If set outside it's allowable range,
  3675.               DATEFORMAT% defaults to 1.  Listed are valid values for
  3676.               DATEFORMAT% and the corresponding valid date formats.
  3677.  
  3678.               DATEFORMAT%    DATE FORMAT            DATE FORMAT
  3679.                           (FIELD WIDTH = 10)     (FIELD WIDTH = 8)
  3680.  
  3681.                  1            MM-DD-YYYY             MM-DD-YY
  3682.                  2            MM/DD/YYYY             MM/DD/YY
  3683.                  3            DD-MM-YYYY             DD-MM-YY
  3684.                  4            DD/MM/YYYY             DD/MM/YY
  3685.                  5            DD.MM.YYYY             DD.MM.YY
  3686.  
  3687.  
  3688.  
  3689.  
  3690.  
  3691.  
  3692.                                        52
  3693.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  3694.  
  3695.  
  3696.  
  3697.  
  3698.  
  3699.  
  3700.  
  3701.  
  3702.  
  3703.                            ISDOT% sets a period or comma for the decimal
  3704.               designator.  If ISDOT% = 1 the decimal designator is a
  3705.               period.  If ISDOT% = 0 the decimal designator is a comma.
  3706.               This is appropriate for some users outside of the USA.
  3707.  
  3708.                            AT1% determines if the cursor will enter
  3709.               input fields used in routines INPTWIND and MULTINPT on the
  3710.               first character of text in the field or after the last
  3711.               character of text in the field.  If AT1% = 1 the cursor
  3712.               will enter a field on the first character of text in the
  3713.               field.  If AT1% = 0 the cursor will enter fields at the
  3714.               position after the last character of text in the field.
  3715.  
  3716.               NOTE: NON-INPUT FIELDS DEFINED IN CALLS TO ROUTINE
  3717.               MAKEFIELD FOR ROUTINE MULTINPT MAY HAVE THE CURSOR SET TO
  3718.               ANY POSITION IN THE FIELD VIA THE CALL TO MAKEFIELD FOR
  3719.               AN INDIVIDUAL FIELD.
  3720.  
  3721.                            BLANK% allows text in input fields used in
  3722.               routines INPTWIND and MULTINPT to be erased when the FIRST
  3723.               valid key is pressed.  If BLANK% = 1 the text in a field
  3724.               will be erased when a valid key is pressed and the
  3725.               character represented by the key will be the first text
  3726.               character in the field.  If BLANK% = 0 the character
  3727.               represented by a valid key, when it is pressed, will be
  3728.               added to any text previously in the field.  The FIRST
  3729.               valid key pressed will not erase the field's text.
  3730.  
  3731.               NOTE: MANY FIELDS USED BY ROUTINE MULTINPT ARE NON-INPUT
  3732.               FIELDS.  THE VALUE OF BLANK% DOES NOT AFFECT THESE FIELDS.
  3733.  
  3734.                            SND% allows the default sound, as set by
  3735.               routine SETWIND, to be generated when and invalid
  3736.               key is pressed in routines INPTWIND and MULTINPT.  If
  3737.               SND% = 1 pressing an invalid character will make the
  3738.               default sound.  If SND% = 0 pressing an invalid character
  3739.               makes no sound.
  3740.  
  3741.  
  3742.          4.01 B4INPT (INPUTEXIT$, RESTRICT$)
  3743.  
  3744.               Description:  Sets "exit keys" and the field restrict
  3745.               string for a subsequent call to INPTWIND.
  3746.  
  3747.               NOTE1: CALLING ROUTINE B4INPT BEFORE A CALL TO ROUTINE
  3748.               INPTWIND IS NOT REQUIRED UNLESS ONE OF B4INPT'S SPECIAL
  3749.               FEATURES ARE REQUIRED.
  3750.  
  3751.               NOTE2: A CALL TO B4INPT ONLY AFFECTS THE NEXT CALL TO
  3752.               INPTWIND.   CALLS TO B4INPT SHOULD BE PLACED DIRECTLY
  3753.               BEFORE CALLS TO INPTWIND.
  3754.  
  3755.  
  3756.  
  3757.  
  3758.                                        53
  3759.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  3760.  
  3761.  
  3762.  
  3763.  
  3764.  
  3765.  
  3766.  
  3767.  
  3768.  
  3769.               EXAMPLE:   CALL B4INPT (.......
  3770.                          CALL INPTWIND (.....   ' this is affected by
  3771.                                                 ' the call to B4INPT.
  3772.                          CALL INPTWIND (.....   ' this is not affected
  3773.                                                 ' by the call to B4INPT.
  3774.  
  3775.               Arguments:   INPUTEXIT$ sets the keys which will exit
  3776.               input routine INPTWIND.  INPUTEXIT$ does not affect input
  3777.               routine MULTINPT.  Routine SETINPT is used to set exit
  3778.               keys for individual MULTINPT screens.  If INPUTEXIT$ = ""
  3779.               the default keys will exit INPTWIND.  The default exit
  3780.               keys are dependent on the number of buttons used by
  3781.               INPTWIND.
  3782.                                               DEFAULT EXIT KEYS
  3783.               NO BUTTONS -------------------- ENTER and ESC
  3784.               ONE BUTTON < OK > ------------- ENTER
  3785.               TWO BUTTONS < OK >< CANCEL > -- ENTER AND ESC
  3786.  
  3787.               ENTER exits INPTWIND returning the edited text.  ENTER
  3788.               always exits all input windows, even if INPUTEXIT$ defines
  3789.               new exit keys.  ESC always exits two button input windows.
  3790.               If INPUTEXIT$ defines new exit keys for input windows
  3791.               without buttons, ESC will not exit unless an "E" is
  3792.               included in INPUTEXIT$.   If ESC is not an exit key the
  3793.               field's text is returned to it's pre-edited state and
  3794.               INPTWIND is not exited if ESC is pressed.  If ESC is an
  3795.               exit key, and it is pressed, INPTWIND is exited returning
  3796.               the EDITED text.  Using INPUTEXIT$ allows additional or
  3797.               different keys to exit INPTWIND.  INPUTEXIT$ may consist
  3798.               of any combination of the following characters.
  3799.  
  3800.               Character                                "Exit" key.
  3801.               "0"                                      F10
  3802.               "1","2","3","4","5","6","7","8","9"      F1 to F9
  3803.               "E"                                      ESC
  3804.               "U"                                      PGUP
  3805.               "D"                                      PGDN
  3806.  
  3807.               "VIEW" -- This causes the input window to be displayed and
  3808.               exited. The input window remains active.
  3809.  
  3810.               NOTE: THE FOLLOWING APPLY FOR NO BUTTON INPUT WINDOWS.
  3811.  
  3812.               "O" - The mouse is pressed outside of the input window.
  3813.               "T" - The TAB or SHIFT/TAB keys exit.
  3814.  
  3815.               NOTE: THE MOUSE "BELONGS" TO ROUTINE INPTWIND IF IT HAS
  3816.               BUTTONS.  INPTWIND CAN NOT BE EXITED IF THE LEFT MOUSE
  3817.               BUTTON IS PRESSED OUTSIDE OF THE FIELD.  TO USE INPUT
  3818.               FIELDS AND DETECT THE IF THE LEFT MOUSE BUTTON IS PRESSED
  3819.               OUTSIDE OF A FIELD ROUTINE "NO BUTTON INPUT WINDOWS" OR
  3820.               MULTINPT MUST BE USED.
  3821.  
  3822.  
  3823.  
  3824.                                        54
  3825.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  3826.  
  3827.  
  3828.  
  3829.  
  3830.  
  3831.  
  3832.  
  3833.  
  3834.  
  3835.               Example: If INPUTEXIT$ = "02E" the F10, F2, ESC, and
  3836.               RETURN (ENTER) keys will exit INPTWIND.  see the
  3837.               description for routine INPTWIND ( argument RKEY% ).
  3838.  
  3839.               The following eliminates ENTER as exit key.
  3840.  
  3841.               DO
  3842.                 CALL B4INPT ("12","")         ' F1 / F2 = exit keys
  3843.                 CALL INPTWIND (........ RKEY% ' SEE ROUTINE INPTWIND
  3844.               LOOP WHILE RKEY% = 13           ' RKEY% = 13 for ENTER
  3845.               CALL RSTRINPT (1)               ' SEE ROUTINE RSTRINPT
  3846.  
  3847.               NOTE: IF THE ESC KEY IS NOT AN EXIT KEY AND INPUTEXIT$
  3848.               DOES NOT EQUAL "" THE ESC KEY WILL RETURN THE TEXT IN THE
  3849.               INPUT FIELD TO IT'S PRE-EDITED STATE. INPTWIND WILL NOT BE
  3850.               EXITED.  IF THE ESC KEY IS AN EXIT KEY INPTWIND IS EXITED
  3851.               RETURNING THE EDITED TEXT, WHEN ESC IS PRESSED.
  3852.  
  3853.                            RESTRICT$ is the field's restrict string. It
  3854.               holds the allowable characters which can be entered in the
  3855.               input field for a subsequent call to INPTWIND.  RESTRICT$
  3856.               IS IGNORED IF THE FIELD IS NOT AN ALPHA/NUMERIC FIELD.
  3857.               Only use RESTRICT$ if necessary.  For example if RESTRICT$
  3858.               = "1234567890()-" only the  characters included in a phone
  3859.               number can be entered in the field. If RESTRICT$ = "" for
  3860.               an alpha/numeric field all valid alpha/numeric characters
  3861.               may be entered in the field.
  3862.  
  3863.  
  3864.          4.02 INPTWIND ( P$, CODE$, TR%, LC%, WD%, WATTR%, FATTR%,
  3865.                          RTRN$, RKEY%, BUT%, BRDR%)
  3866.               See: Example - Input window
  3867.  
  3868.               NOTE1: PLACE THE ABOVE CALL TO INPTWIND ON ONE LINE IN THE
  3869.               QB/QBX ENVIRONMENT.
  3870.  
  3871.               NOTE2: ROUTINES INPTINIT AND SETWIND MUST BE CALLED AT LEAST
  3872.               ONCE IN ANY PROGRAM PRIOR TO CALLING THIS ROUTINE.
  3873.  
  3874.               NOTE3: WHEN AN INPUT WINDOW ( OR LINE ) IS MADE IT BECOMES
  3875.               THE ACTIVE INPUT WINDOW UNTIL IT IS DEACTIVATED BY A CALL
  3876.               TO ROUTINE RSTRINPT.  ON ENTRY THIS ROUTINE WILL MAKE A
  3877.               NEW INPUT WINDOW IF THERE IS NO ACTIVE INPUT WINDOW.  IF
  3878.               THERE IS AN ACTIVE INPUT WINDOW THIS ROUTINE SIMPLY RE-
  3879.               ENTERS IT.  A NEW INPUT WINDOW IS NOT MADE.  AN
  3880.               UNDERSTANDING OF ROUTINE RSTRINPT IS NECESSARY TO FULLY
  3881.               UNDERSTAND THIS ROUTINE.
  3882.  
  3883.               Description: On entry this routine will do one of the
  3884.               following.
  3885.  
  3886.               1. IF THERE IS NO ACTIVE INPUT WINDOW this routine makes
  3887.  
  3888.  
  3889.  
  3890.                                        55
  3891.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  3892.  
  3893.  
  3894.  
  3895.  
  3896.  
  3897.  
  3898.  
  3899.  
  3900.  
  3901.                  an input field, which may optionally be windowed. The
  3902.                  area under the field or window is automatically saved.
  3903.                  The input window becomes the active input window.
  3904.                  The area under the window ( or line ) can be restored
  3905.                  after exiting INPTWIND by calling routine RSTRINPT.
  3906.                  RSTRINPT also deactivates the active input window.
  3907.  
  3908.               2. IF THERE IS AN ACTIVE INPUT WINDOW calling INPTWIND re-
  3909.                  enters it.  Arguments for top row (TR%), left column
  3910.                  (LC%), field width (WD%) and color (ATTR%) are ignored.
  3911.                  A new input window is NOT made.  The active input
  3912.                  window ( from a previous call to INPTWIND ) is used and
  3913.                  MUST be intact.  The following outlines the suggested
  3914.                  use for routines INPTWIND and RSTRINPT.
  3915.  
  3916.                  A.  Call INPTWIND.  Enter data and exit.
  3917.  
  3918.                  B.  Check the data.
  3919.  
  3920.                  C.  If the data is good proceed to step D.  If the data
  3921.                      is not good go back to step A.  As RSTRINPT has not
  3922.                      been called the input window is still active.  A
  3923.                      new input window will not be made.  The existing
  3924.                      active input window is simply re-entered.
  3925.  
  3926.                  D.  Call RSTRINPT.  The active input window made in
  3927.                      step A is deactivated by RSTRINPT.  The display
  3928.                      area covered by the input window may optionally be
  3929.                      restored.  The next call to INPTWIND will make a
  3930.                      new input window as an active input window will not
  3931.                      exist.
  3932.  
  3933.               IF AN ACTIVE INPUT WINDOW UNKNOWINGLY EXISTS ON ENTRY TO
  3934.               INPTWIND THE ACTIVE INPUT FIELD WILL BE DISPLAYED.  THE
  3935.               INPUT WINDOW WILL NOT BE DISPLAYED.  THE LOCATION OF THE
  3936.               FIELD WILL BE THE LOCATION SET BY THE ACTIVE INPUT WINDOW.
  3937.               THE COORDINATES IN THE CALL TO INPTWIND ARE IGNORED.  IF
  3938.               AN INPUT FIELD IS PLACED AT AN UNEXPECTED SCREEN LOCATION
  3939.               ON A CALL TO INPTWIND AN ACTIVE INPUT WINDOW PROBABLY
  3940.               EXISTS WHEN IT IS NOT EXPECTED TO EXIST.
  3941.  
  3942.               Arguments:   P$ is the message ( prompt ) which will be
  3943.               printed to the left of the input field or in the title
  3944.               box of the window, if one is specified.  If P$ is
  3945.               preceded by a "@" it will be centered in the title box.
  3946.  
  3947.                            CODE$ sets the type of input field and may
  3948.               equal the following.
  3949.  
  3950.               "A"  ------   Alpha/numeric.  All standard keys are active.
  3951.               "U"  ------   Alpha/numeric.  Upper case.
  3952.               "L"  ------   Alpha/numeric.  Lower case.
  3953.  
  3954.  
  3955.  
  3956.                                        56
  3957.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  3958.  
  3959.  
  3960.  
  3961.  
  3962.  
  3963.  
  3964.  
  3965.  
  3966.  
  3967.               "D"  ------   Date.  A date field it can not be exited
  3968.                             unless the date is valid or the field is
  3969.                             blank.  The number keys are active.
  3970.                             Depending on the date format specified in
  3971.                             the call to INPTINPT, the ".", "/" or "-"
  3972.                             key will be active also.  Valid dates range
  3973.                             from 01/01/1901 to 12/31/2099, if the width
  3974.                             of the date field is 10, or 01/01/01 to
  3975.                             12/31/99 if the width of the date field is
  3976.                             8.  SEE DESCRIPTION FOR DATEFORMAT% IN
  3977.                             ROUTINE "INPTINIT".
  3978.  
  3979.               "P0" or "0" - Numeric. The value of the string desig-
  3980.               "P1" or "1"   nates the number of decimal places that
  3981.               "P2" or "2"   will be returned, even if more or less are
  3982.               "P3" or "3"   entered.   The field can not be exited
  3983.               "P4" or "4"   unless the number, fixed to the specified
  3984.               "P5" or "5"   number of decimal places will fit in the
  3985.               "P6" or "6"   the field, or the field is blank.  The
  3986.                             number keys and minus ("-") sign are active.
  3987.                             If the number of decimal places is not zero
  3988.                             the decimal designator ("." or ",") is
  3989.                             active also.  The minus sign will only print
  3990.                             in the first position of the field.  If a
  3991.                             decimal point is in the field another one
  3992.                             can not be entered until the previous one is
  3993.                             deleted.
  3994.  
  3995.               "PR" or "R" - Real number.  All numeric keys, the minus
  3996.                             sign ("-"), and decimal designator are
  3997.                             active.  The same rules apply as for 0 - 6
  3998.                             decimal place numbers.  The number is not
  3999.                             fixed to a specified number of decimal
  4000.                             places, however.
  4001.  
  4002.               NOTE: A NUMERIC FIELD WILL BE PADDED WITH LEADING ZEROS
  4003.               IF CODE$ CONTAINS A "P".
  4004.  
  4005.               EXAMPLE:  CODE$ = "3P" --- This allows numeric input.  It
  4006.               will return the data expanded, or truncated to, 3 digits
  4007.               after the decimal point and padded with leading zeros.
  4008.  
  4009.                             TR% is the top row of the field or window.
  4010.               If a window is designated, TR% must be set to allow the
  4011.               entire input window fit on the display or an error will be
  4012.               reported.  Setting TR% to 100 centers the field, or
  4013.               window, top to bottom on the display.
  4014.  
  4015.                            LC% is the left column.  If a window is
  4016.               designated, LC% must equal 1 to 76 . With no window LC%
  4017.               must equal 1 to 79 If LC% = 100 the field, or window, is
  4018.               centered left to right.  If LC% is set so the input field
  4019.  
  4020.  
  4021.  
  4022.                                        57
  4023.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  4024.  
  4025.  
  4026.  
  4027.  
  4028.  
  4029.  
  4030.  
  4031.  
  4032.  
  4033.               with a window, if specified, or with a prompt, if
  4034.               specified, will not fit on the screen an error will be
  4035.               reported.
  4036.                            WD% is the field's width.  A date field must
  4037.               have WD%=10 or WD%=8.  A numeric field requires WD% to
  4038.               be from the number of ( decimal places + 1 ) to 15.
  4039.               For an alpha/numeric field WD% can range from 1 to 79
  4040.               ( less than 79 if windowed ).
  4041.  
  4042.                            WATTR% is the window's and prompts color.
  4043.               SEE THE COLOR ATTRIBUTE CHART IN THE APPENDIX.
  4044.  
  4045.                            FATTR% is the input field's color
  4046.               SEE THE COLOR ATTRIBUTE CHART IN THE APPENDIX.
  4047.  
  4048.                            RTRN$ is the string passed to, and returned
  4049.               from the input field.  A numeric string can be converted
  4050.               to a number by using the VAL function.
  4051.  
  4052.               EXAMPLE:  IF RTRN$= "123.123" IT CAN BE CONVERTED TO A
  4053.               NUMBER (A) WITH THE STATEMENT:
  4054.  
  4055.                            A = VAL(RTRN$)
  4056.                            A now equals 123.123
  4057.  
  4058.                            RKEY% is returned by INPTWIND.  RKEY%
  4059.               represents the key used to exit INPTWIND and is restricted
  4060.               to those keys specified in the call to B4INPT ( argument
  4061.               INPUTEXIT$ ).  RKEY% may equal the following
  4062.  
  4063.               RKEY%                     KEY WHICH EXITED INPTWIND
  4064.  
  4065.               0 -- RKEY% will equal 0 if the argument INPUTEXIT$ in
  4066.                    routine B4INPT = "VIEW"
  4067.  
  4068.               1 to 10                   F1 to F10
  4069.               11                        PGUP
  4070.               12                        PGDN
  4071.               13                        ENTER or the < OK > BUTTON
  4072.               27                        ESC or the < CANCEL BUTTON >
  4073.  
  4074.               NOTE THE FOLLOWING APPLIES TO NO BUTTON INPUT WINDOWS
  4075.  
  4076.               14                        SHIFT/TAB
  4077.               15                        TAB
  4078.  
  4079.                            BUT% allows < OK > and < CANCEL > buttons for
  4080.               the input window.  Buttons are selected by moving the
  4081.               cursor to the button using the tab or shift tab keys. If
  4082.               ENTER or the SPACE BAR is pressed and the cursor is on a
  4083.               button, the button is selected.  If the mouse is released
  4084.               with the mouse cursor over a button, the button is
  4085.  
  4086.  
  4087.  
  4088.                                        58
  4089.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  4090.  
  4091.  
  4092.  
  4093.  
  4094.  
  4095.  
  4096.  
  4097.  
  4098.  
  4099.               selected.  If BUT% = 1 the < OK > button is displayed.  If
  4100.               BUT% = 2 the < OK > and < CANCEL > buttons are displayed.
  4101.               Selecting the < OK > button simulates pressing the ENTER
  4102.               key on a selection (RKEY% = 13).  Selecting the < CANCEL >
  4103.               button simulates pressing ESC (RKEY% = 27).  IF BUT% = 1
  4104.               the ESC key will not exit unless an "E" is included in
  4105.               routine B4INPT's argument INPUTEXIT$.  Using buttons
  4106.               affects the length ( number of rows ) of the input window
  4107.               as follows.
  4108.  
  4109.                           ( ----------- INPUT WINDOW TYPE ----------- )
  4110.  
  4111.                           UN-WINDOWED      --------- WINDOWED ---------
  4112.               BUTTONS     SINGLE LINE      W/TITLEBOX  WITHOUT TITLEBOX
  4113.  
  4114.                  0        1 ROW             5 ROWS       3 ROWS
  4115.                  1 or 2   2 ROWS            9 ROWS       7 ROWS
  4116.  
  4117.               NOTE: IF A WINDOW SHADOW IS SPECIFIED FOR WINDOWED INPUT
  4118.               FIELDS, THE NUMBER OF ROWS IS INCREASED BY ONE.
  4119.  
  4120.                            BRDR% is the input window's border. ( SEE
  4121.               THE BORDER DESIGNATION CHART ). If BRDR% = 0 and BUT% = 0
  4122.               a single line input field ( no window ) is generated.  If
  4123.               BRDR% produces a title box window, the prompt (P$) is
  4124.               printed in the title box.
  4125.  
  4126.  
  4127.          4.03 RSTRINPT ( RESTOREFLAG% )
  4128.               See: Example - Input window
  4129.  
  4130.               Description: Deactivates the active input window generated
  4131.               by a call to routine INPTWIND.  Optionally restores the
  4132.               display area under the input window.  After a call to
  4133.               INPTWIND an active input window exists.  Subsequent calls
  4134.               to INPTWIND behave differently if, on entry, an active
  4135.               input window exists.
  4136.  
  4137.               Argument:    RESTOREFLAG% must equal 1 to restore the
  4138.               display area ( saved by routine INPTWIND ) under the
  4139.               active input window.  If RESTOREFLAG% equals 0 the
  4140.               area under the active input window is not restored to the
  4141.               display.  REGARDLESS OF THE VALUE OF RESTOREFLAG% ALL
  4142.               CALLS TO RSTRINPT DEACTIVATE THE ACTIVE INPUT WINDOW.
  4143.  
  4144.               EXAMPLES:
  4145.  
  4146.               1. CALL RSTRINPT (1)  'DEACTIVATES ACTIVE INPUT WINDOW
  4147.                                     'AND RESTORES DISPLAY AREA UNDER IT.
  4148.  
  4149.               2. CALL RSTRINPT (0)  'DEACTIVATES ACTIVE INPUT WINDOW.
  4150.  
  4151.  
  4152.  
  4153.  
  4154.                                        59
  4155.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  4156.  
  4157.  
  4158.  
  4159.  
  4160.  
  4161.  
  4162.  
  4163.  
  4164.  
  4165.               NOTE1: IF AN INPUT WINDOW REMAINS ON THE DISPLAY AND IT IS
  4166.               NOT THE ACTIVE INPUT WINDOW, RSTRINPT CAN NOT RESTORE THE
  4167.               DISPLAY AREA UNDER IT.  RSTRINPT CAN ONLY RESTORE THE
  4168.               DISPLAY AREA UNDER THE ACTIVE INPUT WINDOW.
  4169.  
  4170.               NOTE2: THE ACTIVE INPUT WINDOW ( THE SAVED DISPLAY AREA )
  4171.               RESIDES IN WINDOW NUMBER 21.  FUNCTION WAVAIL% CAN
  4172.               DETERMINE IF AN INPUT WINDOW IS ACTIVE.
  4173.  
  4174.               EXAMPLE: IF WAVAIL%(21) = 0 ' An input window is active.
  4175.                        IF WAVAIL%(21) = 1 ' An input window is not
  4176.                                           ' active.
  4177.  
  4178.  
  4179.  
  4180.  
  4181.  
  4182.  
  4183.  
  4184.  
  4185.  
  4186.  
  4187.  
  4188.  
  4189.  
  4190.  
  4191.  
  4192.  
  4193.  
  4194.  
  4195.  
  4196.  
  4197.  
  4198.  
  4199.  
  4200.  
  4201.  
  4202.  
  4203.  
  4204.  
  4205.  
  4206.  
  4207.  
  4208.  
  4209.  
  4210.  
  4211.  
  4212.  
  4213.  
  4214.  
  4215.  
  4216.  
  4217.  
  4218.  
  4219.  
  4220.                                        60
  4221.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  4222.  
  4223.  
  4224.  
  4225.  
  4226.  
  4227.  
  4228.  
  4229.  
  4230.  
  4231.          -----------------------------------------------------------------
  4232.          ' SAMPLE: Input window
  4233.          ' IT IS ASSUMED ROUTINE SETWIND HAS BEEN CALLED.
  4234.          ' BEFORE ANY CALLS TO INPTWIND, INPTINIT MUST BE CALLED.
  4235.  
  4236.          ' DATE FORMAT = "MM-DD-YYYY" OR "MM-DD-YY"
  4237.          ' DECIMAL DESIGNATOR IS A "." -- CURSOR ENTERS FIELD IN POS. 1
  4238.          ' FIELD BLANK ON FIRST KEY PRESSED. -- SOUND MADE FOR BAD KEY
  4239.          CALL INPTINIT ( 1, 1, 1, 1, 1 )
  4240.  
  4241.          '
  4242.          '
  4243.          DO
  4244.          ' NUMERIC INPUT - 0 DECIMAL PLACES.
  4245.          ' INPUT WINDOW CENTERED ROW AND COLUMN.
  4246.          ' FIELD WIDTH = 2.
  4247.          ' WINDOW = BLACK ON WHITE. FIELD = INTENSITY WHITE ON BLACK.
  4248.          ' WINDOWED WITHOUT A TITLE BOX - PROMPT TO LEFT OF INPUT FIELD.
  4249.          ' <OK> AND <CANCEL> BUTTONS
  4250.          ' THE FOLLOWING CALL TO INPTWIND MUST BE ON ONE LINE IN THE QB/QBX
  4251.          ' /VBDOS EDITOR.
  4252.          CALL INPTWIND ("Enter a number 1 to 50: ", "0", 100, 100, 2, 112,
  4253.                          15, RTRN$, RKEY%, 2, 1 )
  4254.  
  4255.          ' RKEY% REPRESENTS KEY USED TO EXIT INPTWIND .
  4256.          ' RTRN$ IS THE ENTERED TEXT.
  4257.  
  4258.          ' RKEY% = 27 IF ESC PRESSED OR < CANCEL > SELECTED
  4259.          IF RKEY% = 27 THEN PRINT "ESC PRESSED OR CANCEL SELECTED":END
  4260.  
  4261.          R% = VAL(RTRN$)
  4262.  
  4263.          ' WAS BAD INPUT. GO BACK TO INPTWIND.  AS RSTRINPT HAS NOT BEEN
  4264.          ' CALLED THE INPUT WINDOW REMAINS ACTIVE.  IT WILL NOT BE RE-
  4265.          ' PRINTED. IT IS RE-ENTERED ONLY.
  4266.  
  4267.          LOOP WHILE R% < 1 OR R% > 50                        ' BAD INPUT
  4268.  
  4269.          ' WAS GOOD INPUT - RSTRINPT DEACTIVATES ACTIVE INPUT WINDOW AND
  4270.          ' RESTORES DISPLAY AREA UNDER SAME.
  4271.          ' *** IF RSTRINPT IS NOT CALLED, ON THE NEXT CALL TO INPTWIND AN
  4272.          ' *** ACTIVE INPUT WINDOW WILL STILL EXIST.  INPTWIND WILL IGNORE
  4273.          ' *** VALUES FOR TOP ROW, LEFT COLUMN, WIDTH AND COLOR AND USE THE
  4274.          ' *** VALUES FROM THE ACTIVE INPUT WINDOW.  FORGETTING TO CALL
  4275.          ' *** RSTRINPT TO DEACTIVATE AN ACTIVE INPUT WINDOW MAY THEREFOR
  4276.          ' *** PRODUCE UNEXPECTED RESULTS.
  4277.  
  4278.          CALL RSTRINPT (1)
  4279.          LOCATE 1, 1
  4280.          PRINT RTRN$ +" WAS ENTERED!"
  4281.          END
  4282.          -----------------------------------------------------------------
  4283.  
  4284.  
  4285.  
  4286.                                        61
  4287.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  4288.  
  4289.  
  4290.  
  4291.  
  4292.  
  4293.  
  4294.  
  4295.  
  4296.  
  4297.                           Multi-field Input Overview
  4298.  
  4299.          The following is an overview of the procedures required to
  4300.          generate a MULTI-FIELD input screen.  The procedures are
  4301.          listed in the order they must be used.
  4302.  
  4303.  
  4304.          1. Call routine INPTINIT.  This sets global variables for all
  4305.             input routines.  It is only necessary to call INPTINIT
  4306.             once in every program.
  4307.  
  4308.          2. Call routine SETINPT.  This sets the properties for an
  4309.             individual MULTI-FIELD input screen.  SETINPT must be
  4310.             called once for every MULTI-FIELD input screen.
  4311.  
  4312.          3. Call routine MAKEFIELD to define each field in the MULTI-
  4313.             FIELD input screen.
  4314.  
  4315.          4. Call routine MULTINPT to display the input fields and
  4316.             receive user input for an individual MULTI-FIELD input
  4317.             screen.  For repeated calls to MULTINPT for a predefined
  4318.             MULTI-FIELD input screen it is not necessary to repeat
  4319.             steps 1, 2, and 3.  Once a MULTI-FIELD input screen is
  4320.             defined it remains defined for subsequents calls to
  4321.             MULTINPT as long as a CLEAR statement has not been
  4322.             executed.
  4323.  
  4324.  
  4325.  
  4326.  
  4327.  
  4328.  
  4329.  
  4330.  
  4331.  
  4332.  
  4333.  
  4334.  
  4335.  
  4336.  
  4337.  
  4338.  
  4339.  
  4340.  
  4341.  
  4342.  
  4343.  
  4344.  
  4345.  
  4346.  
  4347.  
  4348.  
  4349.  
  4350.  
  4351.  
  4352.                                        62
  4353.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  4354.  
  4355.  
  4356.  
  4357.  
  4358.  
  4359.  
  4360.  
  4361.  
  4362.  
  4363.          4.04 SETINPT ( SCRN%, DISPLEN%, EXIT$, HOTCOL% )
  4364.  
  4365.               Description: Defines a multi-field input screen, which will
  4366.               be utilized by a subsequent call to routine MULTINPT.
  4367.  
  4368.               Arguments:   SCRN% is the number of the screen being
  4369.               defined.  SCRN% may range from 1 to 10.
  4370.  
  4371.                            DISPLEN% is the length of the screen ( rows )
  4372.               which will be in effect when the multi-field input screen
  4373.               for the designated screen number is called.  DISPLEN% must
  4374.               equal 25, 43, or 50.  When MULTINPT for this input screen
  4375.               is called the current screen rows must equal those
  4376.               specified in the call to SETINPT for the same input screen
  4377.               or an error will be reported.
  4378.  
  4379.                           EXIT$ is a code for the keys, or mouse
  4380.               condition which will exit the multi-field input routine
  4381.               for the designated screen number.  EXIT$ may be any
  4382.               combination of "0123456789EUDO".  To make the function
  4383.               keys active place their number "1","2" etc in EXIT$.   A
  4384.               "0" ( zero ) represents the F10 key, a "D" the PGDN key ,
  4385.               a "U" the PGUP key and an "E" the ESC key.  The letter "O"
  4386.               in EXIT$ will cause routine MULTINPT to be exited if the
  4387.               left mouse button is pressed while the mouse cursor is NOT
  4388.               in a field.
  4389.  
  4390.               EXAMPLE: IF EXIT$ ="03U" THE F10, F3, OR PGUP KEYS WILL
  4391.               EXIT THE MULTI-FIELD INPUT ROUTINE ( MULTINPT ).
  4392.  
  4393.               NOTE:  If THE ESC KEY IS NOT USED AS AN EXIT KEY IT IS
  4394.               USED TO RETURN THE TEXT OF A FIELD IN MULTINPT TO IT'S
  4395.               PRE-EDITED STATE.  THIS FEATURE IS DISABLED WHEN ESC IS
  4396.               USED AS AN EXIT KEY    THE SPACE BAR CAN ALSO BE AN EXIT
  4397.               KEY FOR INDIVIDUAL FIELDS IN MULTINPT IF A FIELD IS A
  4398.               FIXED CHOICE FIELD.   SEE THE DESCRIPTION FOR ARGUMENT
  4399.               CODE% IN ROUTINE MAKEFIELD TO USE FIXED CHOICE FIELDS.
  4400.  
  4401.                            HOTCOL% sets the color of "key characters"
  4402.               for fields defined in subsequent calls to MAKEFIELD for
  4403.               the specified multi-field input screen.  Key characters
  4404.               may be used to move the cursor to a specific field if the
  4405.               key character for that field is pressed.  Although key
  4406.               characters may be used to move the cursor to an editable
  4407.               input field, key characters are ignored while in an
  4408.               editable field ( the characters are assumed to be input ).
  4409.               Editable input fields allow input.  "Fixed choice" fields
  4410.               which may be used as BUTTONS or for multiple choices are
  4411.               not editable.
  4412.  
  4413.  
  4414.  
  4415.  
  4416.  
  4417.  
  4418.                                        63
  4419.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  4420.  
  4421.  
  4422.  
  4423.  
  4424.  
  4425.  
  4426.  
  4427.  
  4428.  
  4429.          4.05 MAKEFIELD ( SCRN%, FLD%, CODE%, TR%, LC%, WD% INACTIVEATTR%,
  4430.               ACTIVEATTR%,MOUSEATTR%,RES$,EXTO$,HOTPOS%,CURPOS%,BRACKET%)
  4431.  
  4432.               NOTE1: THE ABOVE CALL TO MAKEFIELD MUST BE ON ONE LINE IN THE
  4433.               QB/QBX ENVIRONMENT.
  4434.  
  4435.               NOTE2: ROUTINE SETINPT FOR THE DESIGNATED MULTI-FIELD SCREEN
  4436.               NUMBER ( SCRN% ) MUST BE CALLED PRIOR TO CALLING THIS ROUTINE.
  4437.  
  4438.               Description:  Makes input, fixed choice, or button fields
  4439.               for a multi-field input screen previously defined in call
  4440.               to routine SETINPT.  The fields will be used in a
  4441.               subsequent call to MULTINPT.
  4442.  
  4443.               Arguments:   SCRN% is the multi-input screen for which
  4444.               this routine is making a field.  The multi-input screen
  4445.               MUST have been previously defined by a call to routine
  4446.               SETINPT.
  4447.  
  4448.                            FLD% is the field number being made.  The
  4449.               order in which fields are made, determine the order of
  4450.               input.  Field number 2 can not be made unless field number
  4451.               one has been previously made.  If a field is made for a
  4452.               specified multi-input screen, and the field already
  4453.               exists, the existing field is replaced with the new one.
  4454.               FLD% may range from 1 to 150.
  4455.  
  4456.                            CODE% is the code for type of input field
  4457.               and can be set to any of the following.
  4458.  
  4459.               0 to 6 ----- The field is numeric with the indicated
  4460.                            number of decimal places.
  4461.  
  4462.               10 to 16 --- The field is numeric with padded zeros.
  4463.                            Subtract 10 to obtain the number of decimal
  4464.                            places.
  4465.  
  4466.               30 --------- The field is numeric. It is to be used for
  4467.                            real numbers.
  4468.  
  4469.               40 --------- The field is numeric and padded with leading
  4470.                            zeros.  It is to be used for real numbers.
  4471.  
  4472.               7 ---------- The field is alpha/numeric.
  4473.               8 ---------- The field is a date field.
  4474.               17 --------- The field is alpha/numeric. (upper case)
  4475.               27 --------- The field is alpha/numeric. (lower case)
  4476.  
  4477.               SEE ROUTINE "INPTWIND", ARGUMENT CODE$, FOR A DESCRIP-
  4478.               TION AND INPUT LIMITATIONS FOR FIELDS BASED ON THEIR
  4479.               DESIGNATION.
  4480.  
  4481.  
  4482.  
  4483.  
  4484.                                        64
  4485.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  4486.  
  4487.  
  4488.  
  4489.  
  4490.  
  4491.  
  4492.  
  4493.  
  4494.  
  4495.               Adding 100 to CODE% makes the field protected.  A
  4496.               protected field will be displayed but can not be
  4497.               edited.   A protected field can not be an Auto-advance
  4498.               or Auto-exit field.  If a protected field is defined as
  4499.               an Auto-exit or Auto-advance field the definition is
  4500.               ignored and the field remains a protected field.
  4501.  
  4502.               Adding 1000 to CODE% makes the field an Auto-advance
  4503.               field.  When the cursor reaches the end of an Auto-
  4504.               advance field, via typing a character, it moves to the
  4505.               next field.  ( User defined order. )
  4506.  
  4507.               Adding 10000 to CODE% makes the field an "Auto-exit"
  4508.               field.   The multi-field input routine will be exited
  4509.               whenever the cursor is moved from an "Auto-exit" field.
  4510.  
  4511.               Adding 30000 to CODE% makes the field a "Fixed choice"
  4512.               field.  Multi-field input routine, MULTINPT, will be
  4513.               exited if the space bar is pressed on, or if the cursor
  4514.               is moved from a "fixed choice" field.  MULTINPT will also
  4515.               be exited if the mouse cursor is in a fixed choice field
  4516.               and the left mouse button is simultaneously released.
  4517.               This in makes the field an auto-exit field.  The
  4518.               description for the procedure MULTINPT describes the
  4519.               details of a "fixed choice" field.
  4520.  
  4521.               Fixed choice fields provide several opportunities.
  4522.  
  4523.               1. If a field is made a "fixed choice" field it may be
  4524.                  used as a "button field".  Routine MULTINPT is exited
  4525.                  when the SPACE BAR is pressed while the cursor is in
  4526.                  the field or when the left mouse button is released and
  4527.                  the mouse cursor is in the field.  This emulates
  4528.                  buttons.  EX: CODE%=30007
  4529.  
  4530.               2. If a field is made a "fixed choice" field and also
  4531.                  defined as protected ( CODE% = 30100 ) the field is a
  4532.                  "mouse only selectable field".  The cursor can not be
  4533.                  moved to a "mouse only selectable field" as it
  4534.                  protected ( 100 has been added to CODE% ). A "mouse
  4535.                  only selectable field" may appear as < F1 = EXIT >.
  4536.                  Routine MULTINPT will exit whenever the mouse cursor is
  4537.                  in it and the left mouse button is released.  If the
  4538.                  field appears as < F1 = EXIT > and F1 is an "exit key"
  4539.                  ( from routine SETINPT ) users without a mouse may exit
  4540.                  MULTINPT by pressing F1.  Users with a mouse may use
  4541.                  the mouse or press F1 to exit.  EX: CODE%=30100
  4542.  
  4543.               3. If a field is made a "fixed choice" field it may be
  4544.                  used for fixed choices.  If the space bar is pressed
  4545.                  while the system cursor is in the field, or if the left
  4546.                  mouse button is released while the mouse cursor is in
  4547.  
  4548.  
  4549.  
  4550.                                        65
  4551.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  4552.  
  4553.  
  4554.  
  4555.  
  4556.  
  4557.  
  4558.  
  4559.  
  4560.  
  4561.                  the field routine MULTINPT is exited.  The field may be
  4562.                  updated with a different choice ( text ) and updated.
  4563.                  Routine MULTINPT is then re-entered.  EX: CODE%=30007
  4564.  
  4565.               EXAMPLE: If CODE%= 11017 THEN CODE% = 10000+1000+17.
  4566.               THE FIELD IS ALPHA/NUMERIC ( UPPER CASE ), AUTO-ADVANCE
  4567.               AND "AUTO-EXIT".
  4568.  
  4569.                ** SEE THE MULTI-FIELD CODE CHART IN THE APPENDIX.**
  4570.  
  4571.                            TR%, LC%, and WD% are the same as in INPTWIND.
  4572.               They represent the field's row position, column position
  4573.               and width.  As in routine INPTWIND the width is dependent
  4574.               on the field type. ( SEE ROUTINE INPTWIND )
  4575.  
  4576.                            INACTIVEATTR% is the field's color when the
  4577.               field is inactive. The field is inactive when the system
  4578.               cursor is NOT in it.
  4579.  
  4580.                            ACTIVEATTR% is the field's color when the
  4581.               field is active.  The field is active when the system
  4582.               cursor is in it.
  4583.  
  4584.                            MOUSEATTR% is the field's color when the
  4585.               field is occupied by the mouse cursor and the left mouse
  4586.               button is pressed.  Usually "button" and "mouse
  4587.               selectable" fields require a different color ( from
  4588.               INACTIVEATTR% ) in MOUSEATTR%.
  4589.  
  4590.                            RES$ defines the allowable characters
  4591.               in a restricted field.  If the field is not set to
  4592.               alpha/numeric by CODE%, RES$ is ignored.  Setting RES$ to
  4593.               "YN" and CODE% TO 17 ( UPPER CASE ) allows the field to
  4594.               respond to Y,y,N or n.  If CODE% = 7 ( UPPER AND LOWER
  4595.               CASE ) and RES$ ="YN" the field is restricted to Y or N.
  4596.               IF CODE%=27 ( LOWER CASE ) and RES$ ="YN" the field will
  4597.               not allow any characters.  If RES$ = "" the field is not
  4598.               restricted and will respond to characters predicated on
  4599.               the value of CODE%.
  4600.  
  4601.               NOTE: IT IS ONLY NECESSARY TO USE RES$ FOR NON-STANDARD
  4602.               FIELDS.  SET RES$ TO "" FOR NORMAL ALPHA/NUMERIC FIELDS
  4603.               OR THE RESULT WILL BE EXTRA CODE AND MEMORY USAGE.  IF
  4604.               THE FIELD IS STANDARD ALPHA/NUMERIC MAKE CODE% = 7 AND
  4605.               RES$ = "".  THIS WILL ALLOW UPPER/LOWER CASE ALPHA/NUM-
  4606.               ERIC INPUT.
  4607.  
  4608.  
  4609.                      EXAMPLE: RES$ = "0123456789-( )"
  4610.  
  4611.                      THIS RESTRICTS INPUT TO CHARACTERS INCLUDED IN
  4612.                      A PHONE NUMBER WITH THE AREA CODE.
  4613.  
  4614.  
  4615.  
  4616.                                        66
  4617.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  4618.  
  4619.  
  4620.  
  4621.  
  4622.  
  4623.  
  4624.  
  4625.  
  4626.  
  4627.                            EXTO$ sets the "exit to character" for the
  4628.               field.  An "exit to character" defines a key, when
  4629.               pressed, which will exit to the field.  If EXTO$ = "A" for
  4630.               a field and an "A" is pressed while the cursor is in a
  4631.               non-editable ( fixed choice ) field, routine MULTINPT is
  4632.               exited.  MULTINPT's argument ( TOFLD% ) which points to
  4633.               the next active field will point to the field number with
  4634.               EXTO$ = "A".  Make EXTO$ ="" if "exit to characters" are
  4635.               not used.
  4636.  
  4637.               NOTE: IF MORE THAN ONE FIELD HAS THE SAME "EXIT TO
  4638.               CHARACTER" ( EXTO$ ) ONLY THE FIRST FIELD IS FOUND. DO NOT
  4639.               USE THE SAME "EXIT TO CHARACTER" FOR MORE THAN ONE FIELD.
  4640.  
  4641.                            HOTPOS% is the position of the character of
  4642.               text in the field which will assume the "key character"
  4643.               color set by routine SETINPT.  This "key character" may be
  4644.               used as the "exit to character".  If HOTPOS% = 0 or
  4645.               HOTPOS% is greater than the strings length a differently
  4646.               colored "key character" will not be displayed. HOTPOS%
  4647.               only applies to "fixed choice fields".
  4648.  
  4649.                            CURPOS% determines the position the cursor
  4650.               will occupy in fixed choice fields when the field is
  4651.               active.  If CURPOS% = 0 or CURPOS% is greater than the
  4652.               fields width the cursor will go to the position as
  4653.               specified by the call to INPTINIT.
  4654.  
  4655.                            BRACKET% is used to set the first and last
  4656.               characters of text in the field to the color, BRACKETATTR%
  4657.               as defined by routine SETWIND.  It is only appropriate for
  4658.               "fixed choice" fields.  If BRACKET% = 1 the first and last
  4659.               character of text in the field assume the BRACKETATTR%
  4660.               color defined in routine SETINPT.  This is only true when
  4661.               the field is the active field. This is useful for button
  4662.               field such as "< OK >".
  4663.  
  4664.  
  4665.          4.06 MULTINPT ( SCRN%, TOFLD%, OPT$, FROMFLD%, RKEY%, RTRN$() SEL%)
  4666.  
  4667.               NOTE1: ROUTINE INPTINIT MUST BE CALLED AT LEAST ONCE IN ANY
  4668.               PROGRAM PRIOR TO CALLING THIS ROUTINE.
  4669.  
  4670.               NOTE2: ROUTINE SETINPT ( FOR THIS SCREEN - SCRN%) MUST BE
  4671.               CALLED SOMETIME IN THE PROGRAM PRIOR TO THIS CALL.
  4672.  
  4673.               Description: Displays input fields defined in a previous
  4674.               call to SETINPT.  Fields are available for full editing
  4675.               Returns edited strings to the calling program.
  4676.  
  4677.               Arguments:   SCRN% is the number ( 1 to 10 ) of the
  4678.               multi-field input screen to display.
  4679.  
  4680.  
  4681.  
  4682.                                        67
  4683.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  4684.  
  4685.  
  4686.  
  4687.  
  4688.  
  4689.  
  4690.  
  4691.  
  4692.  
  4693.                            TOFLD% serves two purposes.
  4694.  
  4695.               1. When entering MULTINPT, TOFLD% determines which field
  4696.                  will be the active field ( the one with the cursor ).
  4697.                  It may range from one to the last field as designated
  4698.                  by SETINPT.  On entry to MULTINPT the field represented
  4699.                  by TOFLD% is always updated.
  4700.  
  4701.               2. When exiting MULTINPT, TOFLD% points to the next field
  4702.                  the cursor would normally occupy.  If a field is an
  4703.                  auto-exit field and the down arrow is pressed, MULTINPT
  4704.                  will be exited.  TOFLD% will point to the field the
  4705.                  cursor would normally occupy via the down arrow being
  4706.                  pressed.  This enables MULTINPT to be exited by an
  4707.                  auto-exit field and re-entered at the correct field.
  4708.                  If the field is a fixed choice field and the space bar
  4709.                  is pressed, TOFLD% will point to the fixed choice field
  4710.                  This is the field the cursor occupied before MULTINPT
  4711.                  was exited.
  4712.  
  4713.                            OPT$ specifies properties of the multi-field
  4714.               input screen.  OPT$ may equal the following.
  4715.  
  4716.               "VIEW"  ------ On entry MULTINPT will fill a single field
  4717.                              or all fields with their respective data.
  4718.                              MULTINPT is then exited.  This is useful
  4719.                              for viewing a multi-field screen and
  4720.                              exiting routine MULTINPT.
  4721.  
  4722.               "U" ---------- This changes the normal field to field
  4723.                              movement of the cursor when using the TAB,
  4724.                              SHIFT TAB, RIGHT ARROW, AND LEFT ARROW
  4725.                              keys to user defined order.  User defined
  4726.                              order is the same order as fields are
  4727.                              defined in routine MAKEFIELD. The TAB and
  4728.                              RIGHT ARROW keys follow user defined order
  4729.                              ( same as ENTER or DOWN ARROW ).  The SHIFT
  4730.                              TAB and LEFT ARROW keys follow reverse user
  4731.                              defined order ( same as UP ARROW ).
  4732.  
  4733.                   ---------- All other string values for OPT$ have no
  4734.                              effect on the multi-field input screen.
  4735.  
  4736.                            FROMFLD% also serves two purposes.
  4737.  
  4738.               1. If FROMFLD% is set to zero, MULTINPT, when entered,
  4739.                  will update all fields.  If FROMFLD%% is set from one
  4740.                  to the last field number only the specified field is
  4741.                  updated.  This allows quick exiting from, and re-
  4742.                  entering of MULTINPT.
  4743.  
  4744.  
  4745.  
  4746.  
  4747.  
  4748.                                        68
  4749.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  4750.  
  4751.  
  4752.  
  4753.  
  4754.  
  4755.  
  4756.  
  4757.  
  4758.  
  4759.               2. When MULTINPT is exited FROMFLD% is set to the last
  4760.                  field that was available for input prior to the exit.
  4761.  
  4762.                  NOTE:  ALTHOUGH THE MOUSE MAY MOVE THE INPUT CURSOR TO
  4763.                  SEVERAL FIELDS PRIOR TO RELEASING THE LEFT MOUSE
  4764.                  BUTTON, FROMFLD% POINTS TO THE LAST FIELD AVAILABLE FOR
  4765.                  INPUT.  IT DOES NOT POINT TO ANY OF THE FIELDS THE
  4766.                  INPUT CURSOR MAY HAVE OCCUPIED WHILE THE LEFT MOUSE
  4767.                  BUTTON WAS PRESSED.
  4768.  
  4769.               It is important to distinguish FROMFLD% from argument
  4770.               TOFLD% which points to the NEXT field the cursor would
  4771.               normally occupy.
  4772.  
  4773.                             RKEY% returns a value designation for the
  4774.               key or feature which caused MULTINPT to be exited or auto-
  4775.               exited.  MULTINPT exits when a valid exit key (specified
  4776.               in the call to SETINPT for the multi-field input screen)
  4777.               is pressed.  MULTINPT is auto-exited whenever the cursor
  4778.               is moved out of an auto-exit  field, or fixed choice
  4779.               field.  MULTINPT is also auto-exited when the SPACE BAR is
  4780.               pressed with the cursor in a fixed choice field.  RKEY%
  4781.               may equal:
  4782.  
  4783.               1 to 10  Exit keys, F1 to F10, caused MULTINPT to be
  4784.                        exited.  MULTINPT was not exited by the auto-exit
  4785.                        feature although the field the cursor occupied on
  4786.                        exit may have been an auto-exit field.
  4787.  
  4788.               11 ----- Exit key, PGUP, caused MULTINPT to be exited.
  4789.                        MULTINPT was not exited by the auto-exit feature
  4790.                        although the field the cursor occupied on exit
  4791.                        may have been an auto-exit field.
  4792.  
  4793.               12 ----- Exit key, PGDN, caused MULTINPT to be exited.
  4794.                        MULTINPT was not exited by the auto-exit feature
  4795.                        although the field the cursor occupied on exit
  4796.                        may have been an auto-exit field.
  4797.  
  4798.               13 ----- The RETURN key caused MULTINPT to be auto-exited.
  4799.                        The field must have been an auto-exit field.
  4800.  
  4801.               14 ----- SHIFT TAB or the LEFT ARROW caused MULTINPT to be
  4802.                        auto-exited.  The field must have been an
  4803.                        auto-exit field.
  4804.  
  4805.               15 ----- The TAB key or RIGHT ARROW caused MULTINPT to be
  4806.                        auto-exited.  The field must have been an auto-
  4807.                        exit field.
  4808.  
  4809.               16 ----- The UP ARROW caused MULTINPT to be auto-exited.
  4810.                        The field must have been an auto-exit field.
  4811.  
  4812.  
  4813.  
  4814.                                        69
  4815.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  4816.  
  4817.  
  4818.  
  4819.  
  4820.  
  4821.  
  4822.  
  4823.  
  4824.  
  4825.               17 ----- The CONTROL-HOME combination caused MULTINPT to
  4826.                        be auto-exited.  The field must have been an
  4827.                        auto-exit field.
  4828.  
  4829.               18 ----- The CONTROL-END combination caused MULTINPT to be
  4830.                        auto-exited.  The field must have been an auto-
  4831.                        exit field.
  4832.  
  4833.               19 ----- The DOWN ARROW caused MULTINPT to be auto-exited.
  4834.                        The field must have been an auto-exit field.
  4835.  
  4836.               20 ----- The AUTO-ADVANCE feature caused MULTINPT to be
  4837.                        auto-exited.  The field must also be an auto-exit
  4838.                        field.  This occurs when the text fills a auto-
  4839.                        advance, auto-exit, field.
  4840.  
  4841.               27 ----- Exit key, ESC, caused MULTINPT to be exited.
  4842.                        MULTINPT was not exited by the auto-exit feature
  4843.                        although field the cursor occupied on exit may
  4844.                        have been an auto-exit field.
  4845.  
  4846.               32 ----- The SPACE BAR caused MULTINPT to be auto-exited.
  4847.                        The field occupied by the cursor on exit must have
  4848.                        been a fixed choice field which is always an auto-
  4849.                        exit field.
  4850.  
  4851.               50 ----- The cursor was in a fixed-choice field ( code =
  4852.                        3xxxx ) and a field "exit to character" was
  4853.                        pressed.  ( SEE ARGUMENT EXTO$ FOR ROUTINE
  4854.                        MAKEFIELD.)
  4855.  
  4856.               100 ---- The mouse selected a new field.  THE MOUSE WAS
  4857.                        RELEASED IN THE NEW FIELD.  The last field that
  4858.                        was available for input was an auto-exit field.
  4859.  
  4860.               200 ---- The mouse was PRESSED outside of a field. RKEY%
  4861.                        can only equal 200 if argument EXIT$ from
  4862.                        routine SETINPT specified an exit when the mouse
  4863.                        is pressed out of a field.
  4864.  
  4865.               300 ---- The mouse selected a new field AND the mouse was
  4866.                        RELEASED outside of the field.  The last field
  4867.                        available for input was an auto-exit field.
  4868.  
  4869.                            RTRN$() is a string array which holds the
  4870.               data to be edited.  Elements of RTRN$() will be
  4871.               displayed in the appropriate fields.  RTRN$(1) will be
  4872.               displayed in field 1 and so on.  Make sure there is not
  4873.               a RTRN$(0) as it will not be displayed.  If a field is
  4874.               numeric, the number to be placed in it must be converted
  4875.               to a string.  Convert the number (A) to a string as
  4876.               follows:   RTRN$(2) = STR$(A)
  4877.  
  4878.  
  4879.  
  4880.                                        70
  4881.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  4882.  
  4883.  
  4884.  
  4885.  
  4886.  
  4887.  
  4888.  
  4889.  
  4890.  
  4891.               When MULTINPT is exited RTRN$() holds the data in it's
  4892.               edited state.
  4893.  
  4894.               On entering MULTINPT, if the field is designated as
  4895.               alpha/numeric and the string will not fit in the field
  4896.               it will be truncated to fit.  If the field is numeric
  4897.               and a number formatted to the correct number of decimal
  4898.               places will not fit in the field, "*"'s will be printed.
  4899.               This will not pose a problem if RTRN$() is initialized
  4900.               via MULTINPT, as MULTINPT will not allow the user to
  4901.               input data longer than the field's width.  If a numeric
  4902.               field is entered with an alpha string the string will
  4903.               print in the field. It is the programmer's responsibility
  4904.               to assure numeric fields contain numeric strings.  IF
  4905.               A FIELD IS NUMERIC WITH 4 DECIMAL PLACES SETTING THE
  4906.               FIELD TO EQUAL "DOG", WILL RESULT IN DOG.0000 BEING
  4907.               DISPLAYED!
  4908.  
  4909.               Use caution if a field is a result of calculation, as
  4910.               the result may be in exponential format.  EXAMPLE:
  4911.  
  4912.                      A = 1       B = 14      C = A/B
  4913.  
  4914.               STR$(C) = "7.142857E-02".  If the field is numeric with
  4915.               four decimal places and set to equal STR$(C) it will
  4916.               print as 7.1428, and not as .0714.
  4917.  
  4918.               To following routine corrects numbers in expoential form
  4919.               for both large and small numbers.  A$ is the numeric
  4920.               string to be displayed in a field.
  4921.  
  4922.               IF INSTR(3, A$, "+") THEN A$ = "9999999999999999"
  4923.               REM: THE NUMBER WAS TOO LARGE ( EX: 2.2D+22 ).  SET TO
  4924.               REM: "9999999999999999" AND "*"'s WILL BE DISPLAYED.
  4925.  
  4926.               IF INSTR(3, A$, "-") THEN
  4927.                  A# = VAL(A$): A# = A# + SGN(A#): A$ = STR$(A#)
  4928.                  IF ABS(A#) > 1 THEN
  4929.                     A$ = MID$(A$, INSTR(A$, "."))
  4930.                     IF A# < 1 THEN A$ = "-" + A$
  4931.                  ELSE
  4932.                     A$="0"
  4933.                  END IF
  4934.               END IF
  4935.               REM: THE NUMBER WAS TOO SMALL. IF A$ = "3.33D-4",
  4936.               REM: A$ WILL NOW = ".000333"
  4937.  
  4938.                            SEL% returns a value if the exit from routine
  4939.               MULTINPT was caused by the mouse selecting a "mouse only
  4940.               selectable field".  SEL% will equal the field number of
  4941.               the "mouse only selectable field" selected by the mouse
  4942.               and argument RKEY% will equal 100 indicating the left
  4943.  
  4944.  
  4945.  
  4946.                                        71
  4947.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  4948.  
  4949.  
  4950.  
  4951.  
  4952.  
  4953.  
  4954.  
  4955.  
  4956.  
  4957.               mouse button was released in the field.  When MULTINPT
  4958.               is exited by a "mouse only selectable field" argument
  4959.               TOFLD% points to the last field occupied by the system
  4960.               cursor. "Mouse only selectable fields" can not be occupied
  4961.               by the system cursor.
  4962.  
  4963.  
  4964.  
  4965.  
  4966.  
  4967.  
  4968.  
  4969.  
  4970.  
  4971.  
  4972.  
  4973.  
  4974.  
  4975.  
  4976.  
  4977.  
  4978.  
  4979.  
  4980.  
  4981.  
  4982.  
  4983.  
  4984.  
  4985.  
  4986.  
  4987.  
  4988.  
  4989.  
  4990.  
  4991.  
  4992.  
  4993.  
  4994.  
  4995.  
  4996.  
  4997.  
  4998.  
  4999.  
  5000.  
  5001.  
  5002.  
  5003.  
  5004.  
  5005.  
  5006.  
  5007.  
  5008.  
  5009.  
  5010.  
  5011.  
  5012.                                        72
  5013.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  5014.  
  5015.  
  5016.  
  5017.  
  5018.  
  5019.  
  5020.  
  5021.  
  5022.  
  5023.        ---------------------------------------------------------------
  5024.              FIELD EDITING FEATURES FOR "MULTINPT" AND "INPTWIND"
  5025.                   ( * = AVAILABLE FOR "MULTINPT" ONLY. )
  5026.        ---------------------------------------------------------------
  5027.        KEY             FUNCTION
  5028.  
  5029.        SPACE BAR       ERASES FIELD - IF IT IS THE FIRST KEY PRESSED.
  5030.  
  5031.        *UP ARROW       MOVES THE CURSOR FROM FIELD TO FIELD AS DETER-
  5032.        *DOWN ARROW     MINED BY THE ORDER DEFINED IN "SETINPT."  THE
  5033.                        DOWN ARROW MOVES THE CURSOR IN ASCENDING FIELD
  5034.                        ORDER. THE UP ARROW MOVES IT IN DESCENDING
  5035.                        FIELD ORDER.  PROTECTED FIELDS ARE SKIPPED.
  5036.  
  5037.        *CTRL END       MOVES THE CURSOR TO THE FIRST OR LAST FIELD AS
  5038.        *CTRL HOME      DESIGNATED BY THE ORDER DEFINED IN "SETINPT".
  5039.  
  5040.        *TAB            MOVES THE CURSOR FROM FIELD TO FIELD HORIZONT-
  5041.        *SHIFT TAB      ALLY. TAB MOVES LEFT TO RIGHT, SHIFT TAB MOVES
  5042.                        RIGHT TO LEFT. PROTECTED FIELDS ARE SKIPPED.
  5043.  
  5044.        CTRL E          ERASES THE FIELD.
  5045.  
  5046.        ESC             RETURNS A FIELD TO IT'S PRE-EDITED STATE OR
  5047.                        EXITS "MULTINPT".  EXITS "INPTWIND" WITH PRE-
  5048.                        EDITED STRING.  ESC EXITS "MULTINPT" IF THE
  5049.                        ESC KEY WAS DESIGNATED AS AND EXIT KEY BY
  5050.                        "SETINPT" ( FIELD NOT RESTORED TO PRE-EDITED
  5051.                        STATE ).
  5052.  
  5053.        ENTER           EXITS "INPTWIND".  SAME AS DOWN ARROW FOR
  5054.        RETURN          "MULTINPT".
  5055.  
  5056.        END             MOVES THE CURSOR TO THE FIRST OR LAST POSITION
  5057.        HOME            OF TEXT WITHIN A FIELD.
  5058.  
  5059.        BACKSPACE       DELETES THE CHARACTER TO THE LEFT OF CURSOR.
  5060.  
  5061.        DELETE          DELETES THE CHARACTER UNDER THE CURSOR AND
  5062.                        SHIFTS CHARACTERS LEFT.
  5063.  
  5064.        INSERT          TOGGLES FROM INSERT TO OVERSTRIKE MODE. IF MODE
  5065.                        IS OVERSTRIKE THE CURSOR IS LARGE. INSERT MODE
  5066.                        IS THE DEFAULT EVERY TIME A FIELD IS ENTERED.
  5067.  
  5068.        RIGHT ARROW     MOVES THE CURSOR LEFT OR RIGHT.  ACTS THE SAME
  5069.        LEFT ARROW      AS TAB OR SHIFT TAB FOR "MULTINPT" IF THE
  5070.                        CURSOR IN POSITION 1 AND THE LEFT ARROW IS
  5071.                        PRESSED, OR THE CURSOR IS AT THE END OF THE
  5072.                        TEXT AND THE RIGHT ARROW IS PRESSED.
  5073.  
  5074.  
  5075.  
  5076.  
  5077.  
  5078.                                        73
  5079.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  5080.  
  5081.  
  5082.  
  5083.  
  5084.  
  5085.  
  5086.  
  5087.  
  5088.  
  5089.          4.07 UPDATEFIELD ( SCRN%, FLD%, TEXT$ )
  5090.  
  5091.               Description: Updates a field in a multi-field input screen
  5092.               generated by routine MULTINPT.
  5093.  
  5094.               NOTE1: THE FIELD TO UPDATE MUST BE DISPLAYED ON THE
  5095.               SCREEN.  IF IT IS NOT DISPLAYED THIS ROUTINE WILL PRINT
  5096.               IT'S TEXT AT THE LOCATION THE FIELD WOULD NORMALLY OCCUPY.
  5097.  
  5098.               NOTE2: ONLY THE FIELD IS UPDATED.  IT IS THE PROGRAMMER'S
  5099.               RESPONSIBILITY TO UPDATE THE ELEMENT OF THE ARRAY HOLDING
  5100.               THE FIELD'S DATA IN ROUTINE MULTINPT. ( SEE ARGUMENT
  5101.               RTRN$() IN ROUTINE MULTINPT )
  5102.  
  5103.               Arguments:   SCRN% is the screen number ( 1 to 10 ) of the
  5104.               multi-field input screen. ( SEE ROUTINES SETINPT AND
  5105.               MULTINPT ).  If SCRN% is not a valid screen number or it
  5106.               is a screen number which has not been pre-defined by
  5107.               routine SETINPT the call to UPDATEFIELD is ignored.
  5108.  
  5109.                            FLD% is the field number of the field to
  5110.               update.  FLD% must be a valid field number for the
  5111.               specified multi-input screen ( SCRN% ) or the call to
  5112.               UPDATEFIELD is ignored.
  5113.  
  5114.                            TEXT$ is the text to print in the field.
  5115.  
  5116.  
  5117.          4.08 GETANS (PROMPT$,CHOICE$,ANS$,TR%,LC%,WATTR%,FATTR%,BORDER%)
  5118.  
  5119.               Description: Generates a prompt with an optional window
  5120.               and pauses, waiting for a single key reply.  The key may
  5121.               be any key or an individual key selected from a definable
  5122.               list.  The prompt may be windowed or on a single line.
  5123.               The key pressed may, or may not be displayed.  If it is
  5124.               displayed ENTER must be pressed to finalize the selection
  5125.               is optional.
  5126.  
  5127.               NOTE: THERE ARE TWO MODES OF OPERATION FOR THIS ROUTINE.
  5128.               SEE THE DESCRIPTION FOR THE ARGUMENT ANS$ FOR DETAILS.
  5129.  
  5130.               Arguments:   PROMPT$ is the prompt ( i.e. Press any key )
  5131.               or question ( i.e. Are you sure?  Y/N ).  It may be
  5132.               optionally windowed ( SEE BORDER% ).  The width of the
  5133.               window is determined by the length of PROMPT$.  If
  5134.               PROMPT$ is too long making the window, or prompt, too
  5135.               wide to fit on the screen an error will be reported.
  5136.  
  5137.                            CHOICE$ is the valid keys the user can
  5138.               press to exit GETANS.  If CHOICE$ = "" any key will
  5139.               exit.  This would be appropriate if PROMPT$ = "Press any
  5140.               key".  If CHOICE$ = "YN" then the "Y", "y", "N" or
  5141.  
  5142.  
  5143.  
  5144.                                        74
  5145.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  5146.  
  5147.  
  5148.  
  5149.  
  5150.  
  5151.  
  5152.  
  5153.  
  5154.  
  5155.               "n" keys will exit GETANS.  The ESC key will always exit
  5156.               regardless of CHOICE$.
  5157.  
  5158.                            ANS$ serves two purposes.  On entry ANS$
  5159.               determines the mode of operation for routine GETANS.
  5160.               There are two modes of operation for this routine.
  5161.  
  5162.               1. If argument ANS$ = "" on entry, as soon as a valid key
  5163.                  is pressed the routine is exited.
  5164.  
  5165.                   EXAMPLE: ANS$ = ""
  5166.                            CALL GETANS ( PROMPT$, "YN", ANS$ ......
  5167.  
  5168.                   As soon a "Y" or "N" is pressed the routine is exited
  5169.                   with the key pressed returned in ANS$
  5170.  
  5171.               2. If argument ANS$ equals any letter on entry the letter
  5172.                  is displayed in the get answer window to the right of
  5173.                  the prompt.  The user may press any valid key
  5174.                  predicated on argument CHOICE$.  The letter represented
  5175.                  by the valid key is displayed in the get answer window.
  5176.                  The user must press ENTER to accept the choice.
  5177.  
  5178.                   EXAMPLE: ANS$ = "N"
  5179.                            CALL GETANS ( PROMPT$, "YN", ANS$........
  5180.  
  5181.                   On entry an "N" will appear after the prompt.  If a
  5182.                   "Y" is pressed it will appear after the prompt.  The
  5183.                   user must press ENTER to exit the routine with the
  5184.                   displayed letter returned in ANS$.
  5185.  
  5186.               On exit ANS$ holds the key pressed.  It is returned in
  5187.               upper case.   If CHOICE$ = "" then ANS$ = "".  If ESC is
  5188.               pressed CHR$(27) is always returned in ANS$.
  5189.  
  5190.                            TR% is the top row.  See MAKEWIND
  5191.  
  5192.                            LC% is the left column.  See MAKEWIND
  5193.  
  5194.                            WATTR% is the window's and text's color
  5195.               designation.  See MAKEWIND.  Although it is permissible to
  5196.               set ATTR% > 127 to make the border flash the text will not
  5197.               flash.
  5198.  
  5199.                            FATTR% is the field's ( if one exists )
  5200.               color.  If ANS$ equals a letter, on entry, the letter is
  5201.               displayed next to the prompt.  The color of this letter is
  5202.               set by FATTR%.
  5203.  
  5204.  
  5205.  
  5206.  
  5207.  
  5208.  
  5209.  
  5210.                                        75
  5211.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  5212.  
  5213.  
  5214.  
  5215.  
  5216.  
  5217.  
  5218.  
  5219.  
  5220.  
  5221.                            BORDER% is the window's border designation.
  5222.               Title boxes ( BORDER% > 42 ) are not permitted.  Set
  5223.               BORDER% to 0 for no window ( prompt only ). SEE THE
  5224.               BORDER DESIGNATION CHART.
  5225.  
  5226.               EXAMPLE OF A CALL TO GETANS:
  5227.  
  5228.               ANS$ = ""
  5229.               CALL GETANS ("Are you sure? Y/N", "YN", ANS$, 100, 100,
  5230.               240, 11)
  5231.               ( Above must be on one line. )
  5232.  
  5233.               A window will be generated with the text "Are you sure?
  5234.               Y/N"  printed in it.  With TR% and LC% set to 100 the
  5235.               window will be centered on the screen ( See MAKEWIND ).
  5236.               ATTR% = 240, therefore, the window will be white with
  5237.               black text and a black flashing border. The user may
  5238.               press the N, n, Y, y, or ESC keys to exit.  The key
  5239.               pressed will be returned to GETANS in the argument ANS$.
  5240.  
  5241.  
  5242.          4.09 CHOICEWIND% (T$,TXT$(),CH$(),TR%,LC%,ATTR%,HATTR%,ESC%,BRDR%)
  5243.               ( CHOICEWIND% is a function )
  5244.  
  5245.               NOTE: ROUTINES INPTINIT AND SETWIND MUST BE CALLED AT LEAST
  5246.               ONCE IN ANY PROGRAM PRIOR TO CALLING THIS ROUTINE.
  5247.  
  5248.               Description: Displays a window containing text.  The
  5249.               window also displays up to ten choices.  A choice may be
  5250.               selected by using the TAB or SHIFT/TAB key to move the
  5251.               cursor to the choice and pressing ENTER or the SPACE BAR.
  5252.               A choice may also be selected by RELEASING the left mouse
  5253.               button while the mouse cursor is on the choice.  The
  5254.               choice window's height is determined by the number of
  5255.               lines of text in it.  The choice window's width is
  5256.               determined by the longest line of text or the width of the
  5257.               choices, whichever is greatest.  CHOICEWIND% returns the
  5258.               number of the selection made by the user, or 27 if ESC is
  5259.               pressed and argument ESC% > 0.
  5260.  
  5261.               Arguments:   T$ is the windows title.  Based on the value
  5262.               of BRDR% ( SEE MAKEWIND ), T$ will print in the window's
  5263.               title box or on the window's top border.
  5264.  
  5265.                            TEXT$() is an array holding the text for each
  5266.               line in the choice window.  TEXT$(1) prints as line one in
  5267.               the choice window.  TEXT$(2) prints as the second line in
  5268.               the choice window.  Each element of TEXT$() represents a
  5269.               line in the choice window.
  5270.  
  5271.               NOTE: TEXT$() DETERMINES THE NUMBER OF LINES IN THE CHOICE
  5272.               WINDOW.  IF TEXT$()'s UPPER BOUND IS TEN ( EX: REDIM
  5273.  
  5274.  
  5275.  
  5276.                                        76
  5277.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  5278.  
  5279.  
  5280.  
  5281.  
  5282.  
  5283.  
  5284.  
  5285.  
  5286.  
  5287.               TEXT$(10) ), TEN LINES WILL BE PRINTED IN THE CHOICE
  5288.               WINDOW.  If TEXT$()'s UPPER BOUND IS ZERO ( EX: REDIM
  5289.               TEXT$(0) ), NO LINES OF TEXT WILL PRINT IN THE CHOICE
  5290.               WINDOW.  THIS MAY BE APPROPRIATE IF THE CHOICE WINDOW'S
  5291.               TITLE ( ARGUMENT T$ ) IS THE ONLY PROMPT REQUIRED.
  5292.  
  5293.               The following applies to TEXT$();
  5294.  
  5295.               1. TEXT$ must ALWAYS be dimensioned prior to any call to
  5296.                  CHOICEWIND%.  If no text is used TEXT$() must be
  5297.                  dimensioned to zero. ( EX: REDIM TEXT$(0) )
  5298.  
  5299.               2. If an element of TEXT$() has a "@" as the first
  5300.                  character, the text will be centered in the choice
  5301.                  window.
  5302.  
  5303.               3. If an element of TEXT$() = "" a blank line will be
  5304.                  printed in the choice window.
  5305.  
  5306.               4. If an element of TEXT$() = "-" a segmenting single line
  5307.                  will print across the choice window.
  5308.  
  5309.               NOTE: TEXT$() IS ERASED BY THE CALL TO CHOICEWIND TO
  5310.               CONSERVE MEMORY. TEXT$() MUST BE REDIMENSIONED PRIOR TO
  5311.               ANY CALL TO CHOICEWIND.
  5312.  
  5313.                            CH$() is an array holding the choices for the
  5314.               choice window.  Each choice is automatically bracketed. If
  5315.               CH$(1) = "OK", it will be displayed as "< OK >".  One to
  5316.               10 choices are permitted
  5317.  
  5318.               NOTE: CH$() IS ERASED BY THE CALL TO CHOICEWIND TO
  5319.               CONSERVE MEMORY. CH$() MUST BE REDIMENSIONED PRIOR TO ANY
  5320.               CALL TO CHOICEWIND.
  5321.  
  5322.                            TR% is the choice window's top row position.
  5323.               If TR% = 100 the choice window is centered top to bottom
  5324.               on the display.
  5325.  
  5326.                            LC% is the choice window's left column
  5327.               position. If LC% = 100 the choice window will be centered
  5328.               left to right on the display.
  5329.  
  5330.                            ATTR% is the color of the choice window and
  5331.               it's text.
  5332.  
  5333.                            HATTR% if not zero allows "key character"
  5334.               selections and sets the key character color of the items
  5335.               in CH$().  The key character is always the first character
  5336.               of each element of CH$().  If HATTR% = 0 key characters
  5337.               are not used.
  5338.  
  5339.  
  5340.  
  5341.  
  5342.                                        77
  5343.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  5344.  
  5345.  
  5346.  
  5347.  
  5348.  
  5349.  
  5350.  
  5351.  
  5352.  
  5353.                            ESC% allows CHOICEWIND% to exit if the ESC
  5354.               key is pressed.  If ESC% = 1 and ESC is pressed
  5355.               CHOICEWIND% will exit with a value of 27.  If ESC% = 0 and
  5356.               ESC is pressed CHOICEWIND% will not be exited.
  5357.  
  5358.                            BRDR% is the choice window's border. ( SEE
  5359.               ARGUMENT BORDER% FOR ROUTINE MAKEWIND. ).  BRDR% may NOT
  5360.               equal zero.
  5361.  
  5362.  
  5363.          4.10 CHOICEBAR% (CH$(), TR%, LC%, WD%, ATTR%, HATTR%, EX$ )
  5364.               ( CHOICEBAR% is a function. )
  5365.  
  5366.               NOTE: ROUTINE INPTINIT MUST BE CALLED AT LEAST ONCE IN ANY
  5367.               PROGRAM PRIOR TO CALLING THIS ROUTINE.
  5368.  
  5369.               Description: Displays one to ten choices on a single line
  5370.               on the display.  A choice may be made by moving the cursor
  5371.               to the choice using the TAB or SHIFT/TAB keys and pressing
  5372.               the ENTER key or the SPACE BAR.  If the left mouse button
  5373.               is released while the mouse cursor is on a choice the
  5374.               selection is made.  CHOICEBAR% returns the following.
  5375.  
  5376.                0 --------- On entry argument EX$ = "VIEW" routine
  5377.                            CHOICEBAR is displayed and exited.
  5378.                1 TO 10 --- Choice 1 to 10 was selected.  Choice 1 is the
  5379.                            leftmost choice, 2 is to the right of 1 etc.
  5380.                11      --- PGUP is an exit key and PGUP was pressed.
  5381.                12      --- PGDWN is an exit key and PGDWN was pressed.
  5382.               -1 TO -10 -- F1 to F10 are exit keys and F1 to F10 was
  5383.                            pressed.
  5384.                27      --- ESC is an exit key and ESC was pressed.
  5385.                15      --- TAB is an exit key and TAB was pressed.
  5386.                14      --- SHIFT/TAB is an exit key and SHIFT/TAB was
  5387.                            pressed.
  5388.                200     --- The left mouse button was pressed outside of
  5389.                            choicebar selections and an "O" was included
  5390.                            in argument EXIT$
  5391.  
  5392.  
  5393.               Arguments:   CH$() is an array holding the choices for the
  5394.               choice bar.  Each choice is automatically bracketed. If
  5395.               CH$(1) = "OK", it will be displayed as "< OK >".  One to
  5396.               10 choices are permitted.
  5397.  
  5398.                            TR% is the choice bar's top row position.
  5399.  
  5400.                            LC% is the choice bar's left column position.
  5401.  
  5402.                            WD% is the width of the choice bar.  The
  5403.               choices are automatically spaced in the choice bar's
  5404.               width.
  5405.  
  5406.  
  5407.  
  5408.                                        78
  5409.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  5410.  
  5411.  
  5412.  
  5413.  
  5414.  
  5415.  
  5416.  
  5417.  
  5418.  
  5419.  
  5420.                            ATTR% is the color of the choice bar and it's
  5421.               text.
  5422.  
  5423.                            HATTR% if not zero allows "key character"
  5424.               selections and sets the key character color of the items
  5425.               in CH$().  The key character is always the first character
  5426.               of each element of CH$().  If HATTR% = 0 key characters
  5427.               are not used.
  5428.  
  5429.  
  5430.                            EX$ is used to provide additional exit keys
  5431.               or alternate ways to exit CHOICEBAR%.  EX$ may equal any
  5432.               combination of "0123456789UDETO" or "VIEW".  Each
  5433.               character in EX$ provides a means of exiting CHOICEBAR as
  5434.               indicated by the following list.
  5435.  
  5436.               "0" ---------- The F10 key exits.
  5437.               "1" to "9" --- The F1 to F9 keys exit.
  5438.               "U" ---------- The PAGE UP key exits.
  5439.               "D" ---------- The PAGE DOWN key exits.
  5440.               "E" ---------- The ESC key exits.
  5441.               "T" ---------- The TAB key and SHIFT/TAB combination exit.
  5442.               "O" ---------- Pressing the left MOUSE button while the
  5443.                              mouse cursor is out of all choices exits.
  5444.               "VIEW" ------- This displays the choicebar only.  Routine
  5445.                              CHOICEBAR is dispalyed and exited.
  5446.  
  5447.  
  5448.               NOTE: THE DISPLAY AREA UNDER A CHICEBAR IS NOT SAVED.  BY
  5449.               PLACING THE CHOICEBAR IN AN EXISTING WINDOW, THIS
  5450.               LIMITATION IS NEGATED.   WHEN ROUTINE RSTRWIND IS CALLED
  5451.               FOR THE EXISTING WINDOW THE AREA UNDER THE WINDOW IS
  5452.               RESTORED.
  5453.  
  5454.  
  5455.  
  5456.  
  5457.  
  5458.  
  5459.  
  5460.  
  5461.  
  5462.  
  5463.  
  5464.  
  5465.  
  5466.  
  5467.  
  5468.  
  5469.  
  5470.  
  5471.  
  5472.  
  5473.  
  5474.                                        79
  5475.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  5476.  
  5477.  
  5478.  
  5479.  
  5480.  
  5481.  
  5482.  
  5483.  
  5484.  
  5485.                       *****  DIRECTORY ROUTINES *****
  5486.  
  5487.          Directory routines compliment features included with QB 4.5
  5488.          BASIC 7.1 ( PDS ) and VB for DOS .  Procedures to find the
  5489.          current disk,  current path, disk capacity, and disk space
  5490.          available are supplied with WINDOWS R-E-Z.  Also included are
  5491.          routines to find the directory of any disk or path.  In
  5492.          addition a file's size, date, time, and attributes can be
  5493.          found.
  5494.  
  5495.          5.00 GETDISK%                ( THIS IS A FUNCTION )
  5496.  
  5497.               Description: Returns the default disk drive. Returns 1
  5498.               drive A:, 2 for B:, 3 for C:, 4 for D: etc.
  5499.  
  5500.               Argument:    None
  5501.  
  5502.               NOTE: DECLARE THIS FUNCTION IN ANY MODULE WHIC USES IT.
  5503.  
  5504.  
  5505.          5.01 FINDPATH$               ( THIS IS A FUNCTION )
  5506.  
  5507.               NOTE: ALWAYS TRAP FOR DISK ERRORS PRIOR TO CALLING THIS
  5508.               FUNCTION.  SEE SECTION " MAKING A DIRECTORY SCROLL
  5509.               WINDOW"
  5510.  
  5511.               Description:  Returns the current path (directory) in the
  5512.               following format, alway starting with the drive letter,
  5513.  
  5514.                      DRIVE:\SUB-DIRECTORY\SUB-DIRECTORY....
  5515.  
  5516.               NOTE: DECLARE THIS FUNCTION IN ANY MODULE WHIC USES IT.
  5517.  
  5518.  
  5519.          5.02 SETDISK (DRIVE%, BADFLAG%)
  5520.  
  5521.               Description: Changes the default drive.
  5522.  
  5523.               Arguments:   DRIVE% is the drive designation.  DRIVE% =
  5524.               1 for drive A:, 2 for B:, 3 for C:, etc.
  5525.  
  5526.                            BADFLAG% = 1 if DRIVE% is less than 1 or
  5527.               greater than the number of logical drives.  BADFLAG% = 0
  5528.               if DRIVE% is in the range from 1 to the number of logical
  5529.               drives in the system.
  5530.  
  5531.               NOTE: A SYSTEM WITH A FLOPPY DRIVE FOR DRIVE A: AND A
  5532.               HARD DISK FOR DRIVE C: HAS 3 LOGICAL DRIVES.  THEREFORE,
  5533.               BADFLAG% WILL = 0 IF DRIVE% = 1 TO 3 EVEN THOUGH A
  5534.               PHYSICAL DRIVE B: DOES NOT EXIST.  ATTEMPTS TO ACCESS
  5535.               DRIVE B: MAY RESULT IN THE DOS MESSAGE. "Place a disk in
  5536.               drive B: and press any key" BEING DISPLAYED.
  5537.  
  5538.  
  5539.  
  5540.                                        80
  5541.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  5542.  
  5543.  
  5544.  
  5545.  
  5546.  
  5547.  
  5548.  
  5549.  
  5550.  
  5551.          5.03 DISKSIZE (DRIVE%, SIZE&, FREE&)
  5552.  
  5553.               NOTE: ALWAYS TRAP FOR DISK ERRORS PRIOR TO CALLING THIS
  5554.               ROUTINE.  SEE SECTION " MAKING A SCROLL DIRECTORY
  5555.               WINDOW".
  5556.  
  5557.               Description: Retrieves disk space and disk free space.
  5558.  
  5559.               Arguments:   DRIVE% is the drive designation.  It
  5560.               follows the same rules as detailed in SETDISK.  The note
  5561.               for SETDISK applies.
  5562.  
  5563.                            SIZE& is the size in bytes of disk space.
  5564.  
  5565.                            FREE& is the size in bytes of free disk
  5566.               space.
  5567.  
  5568.               NOTE: THE ARGUMENTS FOR SIZE AND FREE SPACE ARE LONG
  5569.               INTEGERS.  ANY VARIABLE USED TO REPRESENT THEM MUST BE
  5570.               DESIGNATED AS A LONG INTEGER ( FOLLOWED BY A "&" SIGN )
  5571.               OR A PARAMETER MIS-MATCH WILL BE REPORTED.
  5572.  
  5573.  
  5574.          5.04 FINDDIR (PATH$, TYP$, FILE%)
  5575.  
  5576.               NOTE # 1: THE FOLLOWING MUST BE PLACED BEFORE ANY
  5577.               EXECUTABLE STATEMENTS IN ANY MODULE CALLING "FINDDIR"
  5578.  
  5579.                 TYPE DIREC
  5580.                    SIZE AS LONG
  5581.                    DATE AS STRING * 10
  5582.                    TIME AS STRING * 6
  5583.                    ATTR AS INTEGER
  5584.                 END TYPE
  5585.                 COMMON SHARED /DIRECTORY/ DIREC$(), DIRINFO() AS DIREC
  5586.  
  5587.               NOTE # 2: ALWAYS TRAP FOR DISK ERRORS PRIOR TO CALLING
  5588.               THIS ROUTINE.  SEE SECTION " MAKING A SCROLL DIRECTORY
  5589.               WINDOW"
  5590.  
  5591.               Description:  Puts the directory listing of the
  5592.               specified path in an array, DIREC$().  If a long
  5593.               directory search is requested the files size, date, time
  5594.               and attributes are also placed in array, DIRINFO().  The
  5595.               arrays MUST be defined as explained above in NOTE # 1.
  5596.  
  5597.               Arguments:    PATH$ is the path for the directory
  5598.               listing search.  It must be in the same format as
  5599.               returned by the procedure FINDPATH.  It may be expanded
  5600.               to restrict the search.  Wildcards are permitted.
  5601.  
  5602.               EXAMPLE: IF PATH$ = "C:\TEST\*.BAS", THE SEARCH WILL
  5603.  
  5604.  
  5605.  
  5606.                                        81
  5607.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  5608.  
  5609.  
  5610.  
  5611.  
  5612.  
  5613.  
  5614.  
  5615.  
  5616.  
  5617.               FIND FILES IN DRIVE C:, SUB-DIRECTORY "TEST", WITH THE
  5618.               EXTENSION ".BAS".
  5619.  
  5620.                             TYP$ restricts or expands the search to
  5621.               include files with specified attributes.  An "L" in TYP$
  5622.               tells FINDDIR to make a long directory search.  The
  5623.               file's size, date, time and attributes are found in a
  5624.               long directory search, in addition to the files name,
  5625.               TYP$ may contain any combination of the following:
  5626.  
  5627.                            A - file's archive bit is set
  5628.                            H - hidden files
  5629.                            S - system files
  5630.                            R - read only files
  5631.                            D - sub-directory listings
  5632.                            V - volume entry
  5633.                            O - no file attribute
  5634.                            L - long directory search - SEE ABOVE
  5635.  
  5636.               EXAMPLE:  IF TYP$ = "HS" ONLY HIDDEN AND SYSTEM FILES
  5637.               WILL BE FOUND.
  5638.  
  5639.                            FILE% is the number of files found.  FILE% =
  5640.               0 if no files were found.
  5641.  
  5642.               If files are found their names are placed in the array,
  5643.               DIREC$().  A long directory search places the file's
  5644.               size, date, time and attribute designation in
  5645.               DIRINFO().
  5646.  
  5647.               DIREC$(1) = The name of first file found.
  5648.               DIRINFO(1).SIZE = The size of the file.
  5649.               DIRINFO(1).DATE = The files creation or last update date.
  5650.               DIRINFO(1).TIME = The files creation or last update time.
  5651.               DIRINFO(1).ATTR = The files attribute designation.
  5652.  
  5653.               The following describes DIRINFO(1).ATTR;
  5654.  
  5655.               IF DIRINFO(1).ATTR AND 1 the file is a read only file.
  5656.               IF DIRINFO(1).ATTR AND 2 the file is a hidden file.
  5657.               IF DIRINFO(1).ATTR  AND 4 the file is a system file.
  5658.               IF DIRINFO(1).ATTR  AND 8 the entry is a volume entry.
  5659.               IF DIRINFO(1).ATTR  AND 16 the entry is a sub-directory.
  5660.               IF DIRINFO(1).ATTR  AND 32 the files archived bit is set.
  5661.               IF DIRINFO(1).ATTR  = 0 the file has no attribute.
  5662.  
  5663.               NOTE:  WHEN FINDDIR IS CALLED THE ARRAY, DIREC$() IS
  5664.               AUTOMATICALLY DIMENSIONED TO THE NUMBER OF FILES FOUND.
  5665.               THE ARRAY, DIRINFO() IS ALSO DIMENSIONED TO THE NUMBER
  5666.               OF FILES FOUND PROVIDING THE DIRECTORY SEARCH IS A LONG
  5667.               DIRECTORY SEARCH.  EACH FILE FOUND USES ABOUT 16 BYTES
  5668.               OF MEMORY PLUS AN ADDITIONAL 22 BYTES IF THE DIRECTORY
  5669.  
  5670.  
  5671.  
  5672.                                        82
  5673.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  5674.  
  5675.  
  5676.  
  5677.  
  5678.  
  5679.  
  5680.  
  5681.  
  5682.  
  5683.               SEARCH IS LONG.  TO RECLAIM THE MEMORY ( AFTER USING THE
  5684.               INFORMATION RETURNED BY THE CALL TO FINDDIR ) THE ARRAYS
  5685.               MUST BE ERASED VIA THE STATEMENT:
  5686.  
  5687.                            ERASE DIREC$, DIRINFO
  5688.  
  5689.  
  5690.  
  5691.  
  5692.  
  5693.  
  5694.  
  5695.  
  5696.  
  5697.  
  5698.  
  5699.  
  5700.  
  5701.  
  5702.  
  5703.  
  5704.  
  5705.  
  5706.  
  5707.  
  5708.  
  5709.  
  5710.  
  5711.  
  5712.  
  5713.  
  5714.  
  5715.  
  5716.  
  5717.  
  5718.  
  5719.  
  5720.  
  5721.  
  5722.  
  5723.  
  5724.  
  5725.  
  5726.  
  5727.  
  5728.  
  5729.  
  5730.  
  5731.  
  5732.  
  5733.  
  5734.  
  5735.  
  5736.  
  5737.  
  5738.                                        83
  5739.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  5740.  
  5741.  
  5742.  
  5743.  
  5744.  
  5745.  
  5746.  
  5747.  
  5748.  
  5749.                    ***** MAKING A DIRECTORY SCROLL WINDOW *****
  5750.  
  5751.               REM: THIS EXAMPLE FINDS THE DIRECTORY LISTING OF ALL FILES
  5752.               REM: WITH THE ARCHIVE BIT SET IN DRIVE A.  IT PUTS THE LISTING
  5753.               REM: IN A SCROLL WINDOW AND WAITS FOR THE SELECTION OF A
  5754.               REM: FILE.
  5755.  
  5756.               TYPE DIREC                  ' REQUIRED IN ANY MODULE
  5757.                    SIZE AS LONG           ' USING DIRECTORY ROUTINES.
  5758.                    DATE AS STRING * 10
  5759.                    TIME AS STRING * 6
  5760.                    ATTR AS INTEGER
  5761.               END TYPE
  5762.               COMMON SHARED /DIRECTORY/ DIREC$(), DIRINFO() AS DIREC
  5763.               DIM DUMMY$ (0)                    ' FOR INFO-LINE (NOT USED)
  5764.               CALL SETWIND(1, 1, 7,0 , 15 )     ' INITIALIZE
  5765.           START:
  5766.               CLS
  5767.               ON ERROR GOTO DISKERROR    ' ALWAYS TRAP FOR DISK
  5768.                                          ' ERRORS.
  5769.  
  5770.               REM: AS TYP$ INCLUDES AN "A", THE  FOLLOWING CALL TO
  5771.               REM: FINDDIR PLACES FILES WITH THE ARCHIVE BIT SET FROM
  5772.               REM: DRIVE A:, ("A:\"), IN DIREC$().  AS TYP$ INCLUDES AN "L"
  5773.               REM: THE FILES SIZE, DATE, TIME AND ATTRIBUTES ARE PLACED IN
  5774.               REM: DIRINFO().  FILE% HOLDS THE NUMBER OF FILES FOUND.
  5775.  
  5776.               TYP$ ="AL"
  5777.               CALL FINDDIR ("A:\", TYP$, FILE%)
  5778.  
  5779.               IF FILE% > 0 THEN       ' ONLY IF FILES EXISTED.
  5780.  
  5781.                   REM: MAKE A WINDOW.  STATEMENT MUST BE ON 1 LINE
  5782.  
  5783.                   CALL MAKEWIND(1 ,"@Select file - Press ENTER",
  5784.                   100 ,100 ,30 ,10 ,15 ,101)
  5785.  
  5786.                   REM: MAKE IT AN AUTO-EXIT SCROLL WINDOW.
  5787.  
  5788.                   ' Following must be on one line.
  5789.                   CALL SCRLWIND(DIREC$(), DUMMY$(),"", FILE%, "",
  5790.                                 RTRN%, 1, 1, RKEY%, 0, 1, 0)
  5791.  
  5792.                   IF RKEY% <> 27 THEN
  5793.                       LOCATE 1,1
  5794.                       PRINT "FILE .......";DIREC$(RTRN%)
  5795.                       PRINT "SIZE........";DIRINFO(RTRN%).SIZE
  5796.                       PRINT "DATE........";DIRINFO(RTRN%).DATE
  5797.                       PRINT "TIME........";DIRINFO(RTRN%).TIME
  5798.                       PRINT "ATTRIBUTE...";DIRINFO(RTRN%).ATTR
  5799.                       ERASE DIREC$, DIRINFO
  5800.                    END IF
  5801.  
  5802.  
  5803.  
  5804.                                        84
  5805.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  5806.  
  5807.  
  5808.  
  5809.  
  5810.  
  5811.  
  5812.  
  5813.  
  5814.  
  5815.  
  5816.                    CALL RSTRWIND(1,1)        ' REMOVE THE WINDOW
  5817.  
  5818.                    IF RTRN%=27 THEN GOTO START 'ESC WAS PRESSED
  5819.               ELSE             ' FILE% = 0 ( NO FILES WERE FOUND )
  5820.                    PRINT "NO FILES WERE FOUND"
  5821.               END IF
  5822.               ON ERROR GOTO 0             ' TURN OFF ERROR DETECTION
  5823.  
  5824.               END
  5825.  
  5826.               DISKERROR:
  5827.  
  5828.               REM: ERR = ERROR NUMBER. THIS ERROR HANDLING ROUTINE
  5829.               REM: WILL DETECT IF DISK IS NOT READY, NOT AVAILABLE,
  5830.               REM: OR PATH WAS BAD.
  5831.               SELECT CASE ERR
  5832.                  CASE 71
  5833.                     E$ = "DISK NOT READY"
  5834.                  CASE 68
  5835.                     E$ = "DISK NOT AVAILABLE"
  5836.                  CASE 76
  5837.                     E$ = "PATH NOT FOUND"
  5838.                  CASE ELSE
  5839.                     E$ = "UN-IDENTIFIED DISK ERROR"
  5840.               END SELECT
  5841.  
  5842.               REM: FOLLOWING MUST BE ON ONE LINE
  5843.  
  5844.               CALL GETANS("DISK ERROR: " + E$ + " Press any key.."
  5845.               ,"", "",100 ,100, 143, 15, 1)
  5846.  
  5847.               RESUME START
  5848.  
  5849.  
  5850.  
  5851.  
  5852.  
  5853.  
  5854.  
  5855.  
  5856.  
  5857.  
  5858.  
  5859.  
  5860.  
  5861.  
  5862.  
  5863.  
  5864.  
  5865.  
  5866.  
  5867.  
  5868.  
  5869.  
  5870.                                        85
  5871.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  5872.  
  5873.  
  5874.  
  5875.  
  5876.  
  5877.  
  5878.  
  5879.  
  5880.  
  5881.                      ****  KEYBOARD AND MOUSE ROUTINES ****
  5882.  
  5883.          Adding the ability to "access the mouse" these routines provide
  5884.          increased flexibility over BASIC's INKEY$ statement.
  5885.  
  5886.          NOTE: MOST OF THESE ROUTINES ARE ASSEMBLY ROUTINES.   ALWAYS
  5887.          PLACE THEM IN DECLARE STATEMENTS IN ANY MODULE WHICH USES THEM.
  5888.          THIS WILL ASSURE ARGUMENT MATCHING AND PREVENT ACCIDENTAL
  5889.          PROGRAM "CRASHES".
  5890.  
  5891.  
  5892.          6.00 GETAKEY%
  5893.  
  5894.               Description: GETAKEY% is a function.   It returns a
  5895.               value for the next character in the keyboard buffer or
  5896.               zero if no character is in the keyboard buffer.  If the
  5897.               key pressed represents a standard ASCII/IBM character, the
  5898.               code for the character ( 1 to 255 ) is returned in
  5899.               GETAKEY%.  If the key pressed produces an extended scan
  5900.               code such as the up arrow, the extended scan code for the
  5901.               key multiplied by 256 is returned in GETAKEY%.  GETAKEY%
  5902.               returns  18432 ( 72 * 256 ) for the up arrow.  For those
  5903.               keys which produce an extended scan code over 127, such
  5904.               as CTRL-PGUP ( 132 ), GETAKEY% returns a negative value.
  5905.  
  5906.               SEE THE GETAKEY CODE CHART IN THE APPENDIX.
  5907.  
  5908.               -------------------------------------------------------
  5909.               'EXAMPLE: WAITS FOR RETURN, "A", DOWN ARROW, OR END.
  5910.               'PRESS END TO END
  5911.  
  5912.                DECLARE FUNCTION GETAKEY%  ( PLACE AT MODULE LEVEL )
  5913.  
  5914.               DO
  5915.                 SELECT CASE GETAKEY%      ' PROGRAM GETS INPUT HERE.
  5916.                   CASE 13                 ' 13 IS ASCII FOR RETURN/ENTER.
  5917.                     PRINT "RETURN"
  5918.                   CASE 65                 ' 65 IS ASCII FOR "A".
  5919.                     PRINT "A"
  5920.                   CASE 80 * 256           ' 80 IS THE EXTENDED SCAN.
  5921.                     PRINT "DOWN ARROW"    ' CODE FOR THE DOWN ARROW.
  5922.                   CASE ELSE
  5923.                 END SELECT
  5924.               LOOP WHILE A% <> (79 * 256) ' 79 IS THE EXTENDED SCAN
  5925.               PRINT "END"                 ' FOR END.
  5926.               END
  5927.               --------------------------------------------------------
  5928.  
  5929.  
  5930.  
  5931.  
  5932.  
  5933.  
  5934.  
  5935.  
  5936.                                        86
  5937.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  5938.  
  5939.  
  5940.  
  5941.  
  5942.  
  5943.  
  5944.  
  5945.  
  5946.  
  5947.          6.01 CLEARKB
  5948.  
  5949.               Description: Clears all characters from the type ahead
  5950.               keyboard buffer.
  5951.  
  5952.               Arguments:   None
  5953.  
  5954.  
  5955.          6.02 MOUSEON% (ISON%)  ( FUNCTION )
  5956.  
  5957.               Description: Sets the mouse status and initializes the
  5958.               mouse.  Returns 1 if the mouse driver is present, the
  5959.               mouse hardware is present, and the mouse is set on by
  5960.               argument ISON%.  If the preceding conditions are not
  5961.               true MOUSEON% returns 0.
  5962.  
  5963.               Arguments:   ISON% turns the mouse off or attempts to
  5964.               turn the mouse on.  If ISON% = 1, and the mouse driver and
  5965.               hardware are present, the mouse will be turned on.  The
  5966.               mouse cursor will be visible and positioned on row one and
  5967.               column one of the display.  If ISON% = 0 the mouse is
  5968.               turned off, and the mouse cursor is hidden.
  5969.  
  5970.  
  5971.          6.03 MOUSEHIDE
  5972.  
  5973.               Description: Hides the mouse cursor.  Decrements the
  5974.               mouse "visibility flag" by one.  ( SEE MOUSESHOW )
  5975.  
  5976.               Arguments:   None
  5977.  
  5978.  
  5979.          6.04 MOUSESHOW
  5980.  
  5981.               Description: Displays the mouse cursor. Increments the
  5982.               mouse  "visibility flag" by one.
  5983.  
  5984.               NOTE: FOR EVERY CALL TO MOUSEHIDE A SUBSEQUENT CALL TO
  5985.               MOUSESHOW IS REQUIRED TO DISPLAY THE MOUSE CURSOR.  TWO
  5986.               CONSECUTIVE CALLS TO MOUSEHIDE REQUIRE TO CONSECUTIVE
  5987.               CALLS TO MOUSESHOW TO DISPLAY THE MOUSE.  THE REVERSE
  5988.               IS NOT TRUE.
  5989.  
  5990.               EXAMPLE: ( ASSUMES THE MOUSE CURSOR IS VISIBLE )
  5991.  
  5992.               CALL MOUSEHIDE  ' Mouse cursor hidden - "visibility
  5993.                               ' flag" is decremented.
  5994.  
  5995.               CALL MOUSEHIDE  ' "visibility flag" decremented again.
  5996.  
  5997.               CALL MOUSESHOW  ' "Visibility flag" incremented.  Mouse
  5998.                               ' is still hidden.
  5999.  
  6000.  
  6001.  
  6002.                                        87
  6003.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  6004.  
  6005.  
  6006.  
  6007.  
  6008.  
  6009.  
  6010.  
  6011.  
  6012.  
  6013.               CALL MOUSESHOW  ' "Visibility flag" incremented.  Mouse is
  6014.                               ' now displayed.
  6015.  
  6016.  
  6017.          6.05 MOUSEROW%     ( NOTE: THIS IS A FUNCTION )
  6018.  
  6019.               Description: Returns the row position of the mouse cursor.
  6020.  
  6021.               Arguments:   None
  6022.  
  6023.  
  6024.          6.06 MOUSECOL%     ( NOTE: THIS IS A FUNCTION )
  6025.  
  6026.               Description: Returns the column position of the mouse cursor.
  6027.  
  6028.               Arguments:   None
  6029.  
  6030.  
  6031.          6.07 MOUSEPOS ( ROW%, COLUMN% )
  6032.  
  6033.               Description: Moves the mouse cursor to a specified position.
  6034.  
  6035.               NOTE: IT IS POSSIBLE TO MOVE THE CURSOR OFF OF THE DISPLAY
  6036.  
  6037.               Arguments:   ROW% is the row position.
  6038.  
  6039.                            COLUMN% is the column position.
  6040.  
  6041.  
  6042.          6.08 MOUSELIMIT ( TOPROW%, BOTTOMROW%, LEFTCOL%, RIGHTCOL% )
  6043.  
  6044.               Description: Sets the bounds for mouse cursor movement.
  6045.  
  6046.               Arguments:   TOPROW% is the top row limit of movement
  6047.               for the mouse cursor.
  6048.  
  6049.                            BOTTOMROW% is the bottom row limit of
  6050.               movement for the mouse cursor.
  6051.  
  6052.                            LEFTCOL% is the left column limit of movement
  6053.               for the mouse cursor.
  6054.  
  6055.                            RIGHTCOL% is the right column limit of
  6056.               movement for the mouse cursor.
  6057.  
  6058.          6.09 LBUTTON%     ( NOTE: THIS IS A FUNCTION )
  6059.  
  6060.               Description: Returns the status of the left mouse button.
  6061.               If the left mouse button is pressed LBUTTON% = 1. If the
  6062.               left mouse button is not pressed LBUTTON% = 0.
  6063.  
  6064.               Arguments: None
  6065.  
  6066.  
  6067.  
  6068.                                        88
  6069.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  6070.  
  6071.  
  6072.  
  6073.  
  6074.  
  6075.  
  6076.  
  6077.  
  6078.  
  6079.          6.10 RBUTTON%     ( NOTE: THIS IS A FUNCTION )
  6080.  
  6081.               Description: Returns the status of the right mouse button.
  6082.               If the right mouse button is pressed RBUTTON% = 1. If the
  6083.               right mouse button is not pressed RBUTTON% = 0.
  6084.  
  6085.               Arguments: None
  6086.  
  6087.  
  6088.          6.11 MOUSEINWIND% ( WIND% )       ( NOTE: THIS IS A FUNCTION )
  6089.  
  6090.               Description: Returns a value signifying if the mouse
  6091.               cursor is in a specified window.  The returned values
  6092.               may equal the following.
  6093.  
  6094.               0 -- The mouse cursor is not in the specified window or
  6095.                    the specified window does not exist.
  6096.  
  6097.               1 -- The mouse cursor is on the TOP border ( including
  6098.                    the corners ) of the specified window.
  6099.  
  6100.               2 -- The mouse cursor is on the RIGHT border ( excluding
  6101.                    the corners ) of the specified window.
  6102.  
  6103.               3 -- The mouse cursor is on the BOTTOM border ( including
  6104.                    the corners ) of the specified window.
  6105.  
  6106.               4 -- The mouse cursor is on the LEFT border ( excluding
  6107.                    the corners ) of the specified window.
  6108.  
  6109.               5 -- The mouse cursor is in the interior of the specified
  6110.                    window.
  6111.  
  6112.  
  6113.               NOTE: MOUSEINWIND% RETURNS A VALUE BASED ON THE WINDOW'S
  6114.               COORDINATES.  IT IS THE PROGRAMMERS RESPONSIBILITY TO
  6115.               ASSURE THE SPECIFIED WINDOW IS VISIBLE WHEN MOUSEINWIND%
  6116.               IS CALLED.
  6117.  
  6118.               Argument:    WIND% is the number of the window;
  6119.  
  6120.               0 to 20 represent standard windows.
  6121.               21 represents the INPUT window, if one is active.
  6122.               23 represents the PULLDOWN window, if one is active.
  6123.               24 represents the PULLDOWN menubar, if one is active.
  6124.  
  6125.  
  6126.          6.12 MOUSEINMULT% ( MULTSCRN% )    ( NOTE: THIS IS A FUNCTION )
  6127.  
  6128.               Description: Returns the field number of a specified
  6129.               multi-field input screen the mouse cursor occupies or
  6130.               zero if the mouse cursor is not in a field.
  6131.  
  6132.  
  6133.  
  6134.                                        89
  6135.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  6136.  
  6137.  
  6138.  
  6139.  
  6140.  
  6141.  
  6142.  
  6143.  
  6144.  
  6145.               NOTE: IT IS THE PROGRAMMERS RESPONSIBILITY TO ASSURE THE
  6146.               SPECIFIED MULTI-FIELD SCREEN IS DISPLAYED.  IF IT IS NOT
  6147.               AND IT EXISTS, MOUSEINMULT% RETURNS A VALUE AS IF IT IS
  6148.               DISPLAYED.
  6149.  
  6150.               Argument:   MULTSCRN% is a multi-field input screen defined
  6151.               by previous calls to SETINPT and MAKEFIELD, and displayed
  6152.               by MULTINPT.  If MULTSCRN% is out of range ( 1 to 10 ) or
  6153.               set to an undefined input screen, MOUSEINMULT% returns zero.
  6154.  
  6155.  
  6156.  
  6157.  
  6158.  
  6159.  
  6160.  
  6161.  
  6162.  
  6163.  
  6164.  
  6165.  
  6166.  
  6167.  
  6168.  
  6169.  
  6170.  
  6171.  
  6172.  
  6173.  
  6174.  
  6175.  
  6176.  
  6177.  
  6178.  
  6179.  
  6180.  
  6181.  
  6182.  
  6183.  
  6184.  
  6185.  
  6186.  
  6187.  
  6188.  
  6189.  
  6190.  
  6191.  
  6192.  
  6193.  
  6194.  
  6195.  
  6196.  
  6197.  
  6198.  
  6199.  
  6200.                                        90
  6201.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  6202.  
  6203.  
  6204.  
  6205.  
  6206.  
  6207.  
  6208.  
  6209.  
  6210.  
  6211.                         **** INFO-LINE ROUTINES *****
  6212.  
  6213.          These routines allow the programmer to set up and print in an
  6214.          info-line at any location on the screen.  The info-line can be
  6215.          used to print messages, instructions, or a prompt.  Used in
  6216.          conjunction with routines PULLDOWN and SCRLWIND these routines
  6217.          will change the message in the info-line as the scroll bar is
  6218.          moved through the selections in the pulldown and scroll windows.
  6219.  
  6220.  
  6221.          7.00 INFOLINE ( TR%, LC%, WD%, ATTR% )
  6222.  
  6223.               Description: Set up routine for routines PRINTINFO,
  6224.               INFOFIXED, AND RSTRINFO.  Sets the coordinates and the
  6225.               color for the info-line.  Defines the fixed info-string to
  6226.               equal "" ( SEE: INFOFIXED ).  Makes the info-line active.
  6227.               Saves the display area specified by TR%, LC%, and WD%.
  6228.               This area may be restored by calling routine RSTRINFO.
  6229.               INFOLINE DOES NOT PRINT OR DISPLAY THE INFO-LINE.  THIS IS
  6230.               ACCOMPLISHED BY ROUTINE PRINTINFO.  Routine PRINTINFO is
  6231.               incorporated in routines PULLDOWN and SCRLWIND.  It may
  6232.               also be used prior to calling other routines. ( SEE:
  6233.               Examples - Info-line routines )
  6234.  
  6235.               NOTE: IF AN INFO-LINE IS ACTIVE A CALL TO INFOLINE DOES
  6236.               NOTHING EXCEPT TO CHANGE THE COLOR (IF IT IS DIFFERENT) OF
  6237.               THE INFO-LINE FOR SUBSEQUENT CALLS TO PRINTINFO.  THE
  6238.               INFO-LINE IS DEACTIVATED VIA A CALL TO RSTRINFO.
  6239.  
  6240.               Arguments:   TR% is the top row position of the info-line.
  6241.  
  6242.                            LC% is the left column position of the info-
  6243.               line.  If LC% + WD% > 81 an error will be reported.
  6244.  
  6245.                            WD% is the info-lines width.  If WD% + LC% >
  6246.               81 an error will be reported.
  6247.  
  6248.                            ATTR% is the info-lines color ( SEE THE COLOR
  6249.               ATTRIBUTE CHART ).  ATTR% must range from 1 to 255  or it
  6250.               is adjusted to ATTR% AND 127.
  6251.  
  6252.          7.01 PRINTINFO ( INFO$ )
  6253.  
  6254.               Description: Displays the info-line and prints in same.
  6255.               The info-line must have been made active by a previous
  6256.               call to INFOLINE.  If a fixed info-string has been
  6257.               previously defined by a call to routine INFOFIXED,
  6258.               PRINTINFO adds it's text to the fixed info-string and
  6259.               displays the result in the info-line ( SEE: INFOFIXED ).
  6260.               If an info-line is not active PRINTINFO does nothing.  (
  6261.               SEE: Examples  -Info-line routines.
  6262.  
  6263.  
  6264.  
  6265.  
  6266.                                        91
  6267.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  6268.  
  6269.  
  6270.  
  6271.  
  6272.  
  6273.  
  6274.  
  6275.  
  6276.  
  6277.               Argument:    INFO$ is the string which will print in the
  6278.               info-line.  If a fixed info-string has been defined by
  6279.               routine INFOFIXED, INFO$ is added to the fixed info-string
  6280.               with the result printing in the info-line.  If the length
  6281.               of the fixed info-string plus the length of INFO$ will not
  6282.               fit in info-line defined by routine INFOLINE it is
  6283.               truncated to fit.
  6284.  
  6285.  
  6286.          7.02 INFOFIXED ( FIXEDINFO$ )
  6287.  
  6288.               Description: Defines a fixed info-string which will print
  6289.               every time routine PRINTINFO is called.  As PRINTINFO is
  6290.               called for every entry in a scroll or pulldown window,
  6291.               INFOFIXED is useful for these routines.  The info-line
  6292.               must be active or INFOFIXED does nothing.
  6293.               ( SEE: Examples - Info-line routines )
  6294.  
  6295.               Argument:    FIXEDINFO$ is the fixed info-string.  It will
  6296.               remain the fixed info-string until routine RSRTINFO is
  6297.               called with argument DELFLAG% = 1 ( SEE: RSTRINFO ).  The
  6298.               fixed info-string may be also disabled by calling
  6299.               INFOFIXED with FIXEDINFO$ equal to "".
  6300.  
  6301.  
  6302.          7.03 RSTRINFO ( DELFLAG% )
  6303.  
  6304.               Description: Restores the display area under the info-
  6305.               line.  This area was saved by a previous call to INFOLINE.
  6306.               If the info-line is not active RSTRINFO does nothing.
  6307.               (SEE: Examples - Info-line routines. )
  6308.  
  6309.               Argument:    DELFLAG% is set to 1 to deactivate the info-
  6310.               line.  If DELFLAG% = 1 the display area saved by routine
  6311.               INFOLINE is restored to the display.  An info-line will no
  6312.               longer be active.  If DELFLAG% = 0 the info-line remains
  6313.               active.  The saved display area is restored.  The saved
  6314.               display are remains in window memory, however.
  6315.               NOTE: THE SAVED DISPLAY AREA RESIDES IN WINDOW NUMBER 25.
  6316.               FUNCTION WAVAIL% CAN DETERMINE IF THE INFOLINE IS ACTIVE.
  6317.  
  6318.               EXAMPLE: IF WAVAIL%(25) = 0 ' The info-line is active.
  6319.                        IF WAVAIL%(25) = 1 ' the info-line is not active.
  6320.  
  6321.  
  6322.  
  6323.  
  6324.  
  6325.  
  6326.  
  6327.  
  6328.  
  6329.  
  6330.  
  6331.  
  6332.                                        92
  6333.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  6334.  
  6335.  
  6336.  
  6337.  
  6338.  
  6339.  
  6340.  
  6341.  
  6342.  
  6343.          -----------------------------------------------------------------
  6344.          ' Example: Info-line routines
  6345.          ' THIS EXAMPLE WILL NOT RUN AS THE CALLS TO INPTWIND, SCRLWIND,
  6346.          ' AND PULLDOWN ARE NOT COMPLETE.
  6347.  
  6348.          ' INFO-LINE TOP ROW = 25
  6349.          ' INFO-LINE LEFT COLUMN = 1
  6350.          ' INFO-LINE WIDTH = 80
  6351.          ' INFO-LINE COLOR = BLACK ON GRAY
  6352.          ' SAVES DISPLAY AREA ( ALL OF ROW 25 AS WIDTH = 80 )
  6353.  
  6354.          CALL INFOLINE ( 25, 1, 80, 112 )     ' INFO-LINE MADE ACTIVE
  6355.  
  6356.          CALL PRINTINFO ( "INPUT YOUR NAME" ) ' PRINT IN INFO-LINE
  6357.  
  6358.          CALL INPTWIND.......                 ' TO INPUT A NAME
  6359.  
  6360.          CALL RSTRINFO ( 0 )       ' DISPLAY AREA UNDER INFO-LINE IS
  6361.                                    ' RESTORED TO DISPLAY.  INFO-LINE
  6362.                                    ' REMAINS ACTIVE.
  6363.  
  6364.          ' **** USE SAME INFO-LINE FOR A SCROLL WINDOW.  IN THIS EXAMPLE
  6365.          ' **** THE INFO-LINE DISPLAYS THE SAME MESSAGE FOR ALL ENTRIES IN
  6366.          ' **** THE SCROLL WINDOW.
  6367.  
  6368.          CALL INFOFIXED ( "MAKE A SELECTION" )
  6369.  
  6370.          DIM INFO$(0)              ' MUST BE DIMENSIONED TO 0 TO DISPLAY
  6371.                                    ' THE FIXED INFO-STRING ONLY.
  6372.  
  6373.          CALL SCRLWIND ( LIST$(), INFO$(), .....  ' MAKE SCROLL WINDOW
  6374.  
  6375.          ' "MAKE A SELECTION" IS PRINTED IN INFO-LINE FOR ALL ENTRIES IN
  6376.          ' THE SCROLL WINDOW.  ROUTINE SCRLWIND INTERNALLY CALLS ROUTINE
  6377.          ' PRINTINFO TO PRINT IN THE INFO-LINE.
  6378.  
  6379.          CALL RSTRINFO ( 0 )       ' DISPLAY AREA UNDER INFO-LINE IS
  6380.                                    ' RESTORED TO DISPLAY.  INFO-LINE
  6381.                                    ' REMAINS ACTIVE.
  6382.  
  6383.          CALL INFOFIXED ( "" )     ' REMOVE FIXED INFO-STRING.
  6384.  
  6385.  
  6386.          ' **** USE SAME INFO-LINE FOR A SCROLL WINDOW.  PRINT A DIFFERENT
  6387.          ' **** MESSAGE FOR EACH ITEM IN THE SCROLL WINDOW.
  6388.  
  6389.          CALL INFOFIXED ( "Directions: " ) ' Set fixed info-string
  6390.  
  6391.          DIM INFO$(3)                      ' The fixed info-string plus
  6392.          INFO$(1) = "Save a file."         ' these elements of INFO$() will
  6393.          INFO$(2) = "Load a file."         ' print for the corresponding
  6394.          INFO$(4) = "Delete a file."       ' entries in the scroll window.
  6395.  
  6396.  
  6397.  
  6398.                                        93
  6399.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  6400.  
  6401.  
  6402.  
  6403.  
  6404.  
  6405.  
  6406.  
  6407.  
  6408.  
  6409.          CALL SCRLWIND ( LIST$(), INFO$()..........
  6410.  
  6411.          ' ** The following will print in the info-line.
  6412.          ' "Directions: Save a file."  prints for scroll window entry 1.
  6413.          ' "Directions: Load a file."  prints for scroll window entry 2.
  6414.          ' "Directions: Save a file."  prints for scroll window entry 3.
  6415.  
  6416.          CALL RSTRINFO ( 0 )       ' DISPLAY AREA UNDER INFO-LINE IS
  6417.                                    ' RESTORED TO DISPLAY.  INFO-LINE
  6418.                                    ' REMAINS ACTIVE.
  6419.  
  6420.          ' **** USE THE SAME INFO-LINE FOR PULLDOWN WINDOWS.  THE FIXED
  6421.          ' **** INFO-STRING STILL EQUALS "Directions".
  6422.  
  6423.          DIM INFO$(20)                     ' The fixed info-string plus
  6424.          INFO$(1) = "Save a file."         ' these elements of INFO$() will
  6425.          INFO$(2) = "Load a file."         ' print for the corresponding
  6426.          INFO$(3) = "Delete a file."       ' entries in the scroll window.
  6427.  
  6428.          '...  DO UP TO THE 20TH ELEMENT OF INFO$
  6429.          '...
  6430.  
  6431.          ' NOTE: INFO$() MUST BE DIMENSIONED TO ZERO ( DIM INFO$(0) ). IF
  6432.          ' THE INFO-LINE IS NOT TO BE USED.  THE TEXT FOR THE INFO-LINE FOR
  6433.          ' THE MENUBAR ITEMS IS SET BY ROUTINE SETPULL.  INFO$() ONLY SETS
  6434.          ' THE TEXT FOR THE INFO-LINE FOR THE SELECTIONS IN THE PULLDOWN
  6435.          ' WINDOWS.
  6436.  
  6437.          CALL PULLDOWN ( INFO$()......
  6438.  
  6439.          ' ** The following will print in the info-line.
  6440.          ' "Directions: Save a file."  for pulldown window entry 1.
  6441.          ' "Directions: Load a file."  for pulldown window entry 2.
  6442.          ' "Directions: Save a file."  for pulldown window entry 3.
  6443.  
  6444.          CALL RSTRINFO ( 0 )       ' DISPLAY AREA UNDER INFO-LINE IS
  6445.                                    ' RESTORED TO DISPLAY.  INFO-LINE
  6446.                                    ' REMAINS ACTIVE.
  6447.  
  6448.  
  6449.          '*** USE SAME INFO-LINE WITH ROUTINE GETANS.  PROMPT IS PRINTED IN
  6450.          '*** INFO-LINE BY PRINTINFO.  GETANS DOES NOT PRINT A PROMPT. IT
  6451.          '*** ONLY WAITS FOR A REPLY.
  6452.  
  6453.          CALL PRINTINFO ( "(Y)es or (N)o ?" ) ' PROMPT USER FOR "Y" OR "N".
  6454.  
  6455.          CALL GETANS ("", "YN", ANS$, 100, 100, 112, 0 )
  6456.  
  6457.          ' GETANS COORDINATES ARE MEANINGLESS AS A PROMPT IS NOT PRINTED.
  6458.          ' COORDINATES MUST STILL BE WITHIN VALID RANGES.  THE BORDER
  6459.          ' DESIGNATION MUST BE SET TO ZERO OR GETANS WILL GENERATE A
  6460.          ' WINDOW.
  6461.  
  6462.  
  6463.  
  6464.                                        94
  6465.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  6466.  
  6467.  
  6468.  
  6469.  
  6470.  
  6471.  
  6472.  
  6473.  
  6474.  
  6475.          CALL RSTRINFO ( 1 )       ' DISPLAY AREA UNDER INFO-LINE RESTORED
  6476.                                    ' TO DISPLAY.
  6477.                                    ' *** AS ARGUMENT = 1 THE INFO-LINE IS
  6478.                                    ' NO LONGER ACTIVE.  INFOLINE MUST BE
  6479.                                    ' CALLED AGAIN TO MAKE IT ACTIVE.
  6480.  
  6481.  
  6482.  
  6483.  
  6484.  
  6485.  
  6486.  
  6487.  
  6488.  
  6489.  
  6490.  
  6491.  
  6492.  
  6493.  
  6494.  
  6495.  
  6496.  
  6497.  
  6498.  
  6499.  
  6500.  
  6501.  
  6502.  
  6503.  
  6504.  
  6505.  
  6506.  
  6507.  
  6508.  
  6509.  
  6510.  
  6511.  
  6512.  
  6513.  
  6514.  
  6515.  
  6516.  
  6517.  
  6518.  
  6519.  
  6520.  
  6521.  
  6522.  
  6523.  
  6524.  
  6525.  
  6526.  
  6527.  
  6528.  
  6529.  
  6530.                                        95
  6531.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  6532.  
  6533.  
  6534.  
  6535.  
  6536.  
  6537.  
  6538.  
  6539.  
  6540.  
  6541.                            MISCELLANEOUS ROUTINES
  6542.  
  6543.  
  6544.          8.00 DOSOUND
  6545.  
  6546.               Description: Makes the default sound, or sound as
  6547.               specified by a previous call to SETWIND.
  6548.  
  6549.               Arguments:    None.
  6550.  
  6551.  
  6552.          8.01 DISPLAYROWS%    ( NOTE: THIS IS A FUNCTION )
  6553.  
  6554.               Description: Returns the number of rows for the active
  6555.               display mode.  DISPLAYROWS% returns 25, 43 or 50
  6556.  
  6557.  
  6558.          8.02 PEEKASM& ( SEGMENT&, OFFSET&, NUMOFBYTES% )
  6559.          ( NOTE: THIS IS A FUNCTION WHICH RETURNS A LONG INTEGER )
  6560.  
  6561.               Description: Returns a value at the specified memory
  6562.               location.  Returns a one, two, three, or four byte value.
  6563.               PEEKASM& can be used to "PEEK" a one to four byte memory
  6564.               location.
  6565.  
  6566.               Arguments:   SEGMENT& is the segment ( DOS CONVENTION ) in
  6567.               memory where the value resides.
  6568.  
  6569.                            OFFSET& is the offset location from SEGMENT&
  6570.               for the value.
  6571.  
  6572.                            NUMOFBYTES% is the number of bytes in the
  6573.               value.  It may equal 1,2,3 or 4.  If NUNOFBYTE% does not
  6574.               equal 1,2,3 or 4 it defaults to one byte.
  6575.  
  6576.  
  6577.          8.03 GETCUR&
  6578.          ( NOTE: THIS IS A FUNCTION WHICH RETURNS A LONG INTEGER )
  6579.  
  6580.               Description:  Returns a long integer which represents the
  6581.               system cursor's size and position.
  6582.  
  6583.               Arguments:    None
  6584.  
  6585.               NOTE: BASIC RETAINS IT'S OWN RECORD OF THE CURSOR POSITION
  6586.               FOR SUBSEQUENT PRINT STATEMENTS.  THIS WILL NOT POSE A
  6587.               PROBLEM IF THE ROUTINES INCLUDED IN WINDOWS R-E-Z ARE USED
  6588.               FOR ALL SCREEN PRINTING
  6589.  
  6590.  
  6591.  
  6592.  
  6593.  
  6594.  
  6595.  
  6596.                                        96
  6597.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  6598.  
  6599.  
  6600.  
  6601.  
  6602.  
  6603.  
  6604.  
  6605.  
  6606.  
  6607.          8.04 SETCUR ( CURPOS& )
  6608.  
  6609.               Description: Restores the cursor size and position save by
  6610.               routine GETCUR&.
  6611.  
  6612.               Arguments:   CURPOS& is a long integer returned by a
  6613.               previous call to GETCUR&
  6614.  
  6615.               NOTE: BASIC RETAINS IT'S OWN RECORD OF THE CURSOR POSITION
  6616.               FOR SUBSEQUENT PRINT STATEMENTS.  THIS WILL NOT POSE A
  6617.               PROBLEM IF THE ROUTINES INCLUDED IN WINDOWS R-E-Z ARE USED
  6618.               FOR ALL SCREEN PRINTING
  6619.  
  6620.  
  6621.          8.05 CUROFF
  6622.  
  6623.               Description: Turns the system cursor off by disabling it's
  6624.               visibility.
  6625.  
  6626.               Arguments:    None
  6627.  
  6628.               NOTE: SAVE THE CURSOR SIZE AND POSITION VIA FUNCTION
  6629.               GETCUR& PRIOR TO USING THIS ROUTINE IF THE CURSOR SIZE
  6630.               AND POSITION ARE TO BE RESTORED AT A LATER TINE USING
  6631.               ROUTINE SETCUR.
  6632.  
  6633.  
  6634.  
  6635.  
  6636.  
  6637.  
  6638.  
  6639.  
  6640.  
  6641.  
  6642.  
  6643.  
  6644.  
  6645.  
  6646.  
  6647.  
  6648.  
  6649.  
  6650.  
  6651.  
  6652.  
  6653.  
  6654.  
  6655.  
  6656.  
  6657.  
  6658.  
  6659.  
  6660.  
  6661.  
  6662.                                        97
  6663.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  6664.  
  6665.  
  6666.  
  6667.  
  6668.  
  6669.  
  6670.  
  6671.  
  6672.  
  6673.                        PROGRAM FORMAT FOR WINDOWS R-E-Z
  6674.  
  6675.           ** NOTE: ALL NUMERIC VALUES MUST BE INTEGERS FOR ALL **
  6676.              PROCEDURES EXCEPT DISKSIZE. ( EX: A%, B%, DEFINT A-F )
  6677.  
  6678.               1. LOAD QUICKBASIC WITH CORRECT LIBRARY.
  6679.  
  6680.                  - UNENHANCED VERSION:
  6681.                  EX: QB/L QBUNEN.QLB    ( QuickBASIC 4.50 )
  6682.                      QBX/L PDSUNEN.QLB  ( BASIC 7.1 - PDS )
  6683.                      VBDOS/L VBUNEN.QLB ( Visual BASIC for DOS )
  6684.  
  6685.                  - ENHANCED VERSION:
  6686.                  EX: QB/L QBALL.QLB     ( QuickBASIC 4.50 )
  6687.                      QBX/L PDSALL.QLB   ( BASIC 7.1 - PDS )
  6688.                      VBDOS/L VBALL.QLB  ( Visual BASIC for DOS )
  6689.  
  6690.               2. DECLARE ALL SUB-ROUTINES AND FUNCTIONS.
  6691.  
  6692.                  REM $INCLUDE: 'DECLARE.INC'
  6693.  
  6694.              ' 3. CALL SETWIND TO INITIALIZE WINDOW MEMORY, INPTINIT TO
  6695.              ' INITIALIZE INPUT ROUTINES.  TURN THE MOUSE ON IF IT EXISTS
  6696.  
  6697.                  CLS
  6698.                  CALL SETWIND(1,1,7,0,15)   'FAST WINDOWS
  6699.                                             'SOUND DEFAULTS TO "CLICK"
  6700.                                             'SHADOW COLOR = GRAY
  6701.                                             'HI INTENSITY IS OK
  6702.                                             'BRACKET COLOR = 15
  6703.  
  6704.                  CALL INPTINIT (1,1,1,1,1)  'DATE = MM-DD-YYYY
  6705.                                             'PERIOD AS DECIMAL POINT
  6706.                                             'CURSOR AT POSITION 1
  6707.                                             'BLANK ON 1ST KEY PRESSED
  6708.                                             'MAKE SOUND ON BAD KEY
  6709.  
  6710.                  JUNK% = MOUSEON (1)        'MOUSE IS ON IF JUNK% <> 0
  6711.  
  6712.              ' 4. CALL SETPULL IF PULLDOWN WINDOWS ARE USED
  6713.  
  6714.                  A%= 25
  6715.                  DIM PWIND$(A%)                    ' SET TEMPORARY
  6716.                                                    ' ARRAY
  6717.                  DIM PULLINFOLINE$(0)              ' INFO-LINE NOT USED
  6718.                  TEMP%=0
  6719.                  WHILE PWIND$(TEMP%) <> "ENDPULL"
  6720.                     TEMP% = TEMP% + 1              ' ALWAYS START AT 1
  6721.                     READ PWIND$(TEMP%)             ' READ DATA FOR
  6722.                  WEND                              ' PULLDOWN WINDOWS
  6723.  
  6724.  
  6725.  
  6726.  
  6727.  
  6728.                                        98
  6729.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  6730.  
  6731.  
  6732.  
  6733.  
  6734.  
  6735.  
  6736.  
  6737.  
  6738.  
  6739.                  CALL SETPULL (1, 1, 80, PWIND$()) ' CALL SETPULL
  6740.                  ERASE PWIND$                      ' AND ERASE ARRAY
  6741.  
  6742.                  ' PULLDOWN WINDOW DATA
  6743.                  DATA THIS,,HELLO,JOE,***
  6744.                  DATA IS,,HOW,ARE,YOU,***
  6745.                  DATA A,,I,AM,FINE,***
  6746.                  DATA SAMPLE,,BYE,***
  6747.                  DATA ENDPULL
  6748.  
  6749.                  ON KEY(1) GOSUB PULL              ' MAKE THE F1 KEY
  6750.                                                    ' THE "HOT" KEY FOR
  6751.                                                    ' PULLDOWN WINDOWS
  6752.  
  6753.               '5. READ DATA FOR SCROLL WINDOW(S)
  6754.  
  6755.                  DIM LIST$(10)                     ' DIMENSION ARRAY
  6756.                  FOR X%= 1 TO 10                   ' AND READ SCROLL
  6757.                   READ LIST$(X%)                   ' WINDOW DATA
  6758.                  NEXT
  6759.  
  6760.                  DATA ONE, TWO, THREE, FOUR, FIVE  ' DATA FOR A SCROLL
  6761.                  DATA SIX, SEVEN, EIGHT, NINE, TEN ' WINDOW
  6762.  
  6763.  
  6764.               '6. SET UP MULTI-FIELD INPUT SCREEN(S)
  6765.                  CALL SETINPT( 1, 25, "12", 15 ) ' DEFINE SCREEN.
  6766.  
  6767.                  FOR X% = 1 TO 3
  6768.                    READ CODE%, TR%, LC%, WD%
  6769.                    CALL MAKEFIELD (1,X%,CODE%,TR%,LC%,WD%,7,7,7,"","",0,0,0)
  6770.                  NEXT
  6771.  
  6772.                  DATA 0,1,1,15
  6773.                  DATA 11007,3,1,40
  6774.                  DATA 108,5,1,10
  6775.  
  6776.  
  6777.              '7. ENTER THE PROGRAM
  6778.                  MAIN:
  6779.                  LOCATE 25, 1 :PRINT "PRESS F1"
  6780.                  KEY (1) ON                 ' TURN ON "HOT" KEY AT
  6781.               '  .                          ' APPROPRIATE SPOT IN
  6782.               '  .                          ' PROGRAM.
  6783.               '  .                          ' WAIT FOR F1 KEY.
  6784.                  GOTO MAIN
  6785.                  REM  PULL IS A SUB ROUTINE WHICH IS ENTERED VIA THE
  6786.                  REM  F1 KEY BEING PRESSED.  THIS SUB DISPLAYS THE
  6787.                  REM  PULLDOWN WINDOW AND WAITS FOR AN ITEM TO BE
  6788.                  REM  SELECTED FROM SAME.  IF THE ESC KEY IS PRESSED
  6789.                  REM  THE PROGRAM RESUMES EXECUTION WHERE IT WAS
  6790.                  REM  INTERRUPTED BY THE F1 KEY.  IF AN ITEM IS
  6791.  
  6792.  
  6793.  
  6794.                                        99
  6795.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  6796.  
  6797.  
  6798.  
  6799.  
  6800.  
  6801.  
  6802.  
  6803.  
  6804.  
  6805.                  REM  SELECTED A ROUTINE IS EXECUTED.  AFTER EXECUT-
  6806.                  REM  ION THE PROGRAM CONTINUES AT MAIN.
  6807.                  REM  THIS IS A SUGGESTION FOR A METHOD TO USE PULL-
  6808.                  REM  DOWN WINDOWS.  ALTERNATE METHODS MAY BE USED,
  6809.                  REM  SUCH AS CALL "PULLDOWN" AT START OF PROGRAM.
  6810.                  REM  AND NOT USING A HOT KEY.
  6811.  
  6812.                  PULL:
  6813.                  KEY (1) OFF
  6814.  
  6815.                  REM: MUST BE ON ONE LINE IN QB, QBX, VBDOS EDITOR.
  6816.                  CALL PULLDOWN (PULLINFOLINE$(), MENUITEM% , WINDITEM%, "E",
  6817.                                RKEY%, 112, 15, 11)
  6818.  
  6819.                  CALL RSTRPULL (1)            ' RESTORE AREA UNDER
  6820.                                               ' PULLDOWN WINDOW.
  6821.                  SELECT CASE MENUITEM%
  6822.  
  6823.                   CASE 1                      ' MENUBAR ITEM = THIS
  6824.                     SELECT CASE WINDITEM%
  6825.                       CASE 1                  ' HELLO
  6826.                '       .                      ' ROUTINE FOR HELLO
  6827.                '       .
  6828.                       CASE 2                  ' JOE
  6829.                '       .                      ' ROUTINE FOR JOE
  6830.                '       .
  6831.                     END SELECT
  6832.  
  6833.                   CASE 2                      ' MENUBAR ITEM = IS
  6834.                     SELECT CASE WINDITEM%
  6835.                       CASE 1                  ' HOW
  6836.                 '      .                      ' ROUTINE FOR HOW
  6837.                 '      .
  6838.                       CASE 2                  ' ARE
  6839.                 '      .                      ' ROUTINE FOR ARE
  6840.                 '      .
  6841.                       CASE 3                  ' YOU
  6842.                 '      .                      ' ROUTINE FOR YOU
  6843.                 '      .
  6844.                     END SELECT
  6845.  
  6846.                   CASE 3                      ' MENUBAR ITEM = A
  6847.                     SELECT CASE WINDITEM%
  6848.                       CASE 1                  ' I
  6849.                 '      .                      ' ROUTINE FOR I
  6850.                 '      .
  6851.                       CASE 2                  ' AM
  6852.                 '      .                      ' ROUTINE FOR AM
  6853.                 '      .
  6854.                       CASE 3                  ' FINE
  6855.                 '      .                      ' ROUTINE FOR FINE
  6856.                 '      .
  6857.  
  6858.  
  6859.  
  6860.                                       100
  6861.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  6862.  
  6863.  
  6864.  
  6865.  
  6866.  
  6867.  
  6868.  
  6869.  
  6870.  
  6871.                     END SELECT
  6872.  
  6873.                   CASE 4                      ' MENUBAR ITEM = SAMPLE
  6874.                 '      .                      ' ROUTINE FOR SAMPLE
  6875.                 '      .                      ' ( OR BYE )
  6876.  
  6877.                   CASE ELSE
  6878.                      END                      ' WAS ESC
  6879.                 END SELECT
  6880.                     KEY (1) ON
  6881.                     RETURN MAIN                ' DONE WITH THE ROUTINE
  6882.                                                ' SELECTED FROM
  6883.                                                ' PULLDOWN WINDOWS
  6884.  
  6885.  
  6886.  
  6887.  
  6888.  
  6889.  
  6890.  
  6891.  
  6892.  
  6893.  
  6894.  
  6895.  
  6896.  
  6897.  
  6898.  
  6899.  
  6900.  
  6901.  
  6902.  
  6903.  
  6904.  
  6905.  
  6906.  
  6907.  
  6908.  
  6909.  
  6910.  
  6911.  
  6912.  
  6913.  
  6914.  
  6915.  
  6916.  
  6917.  
  6918.  
  6919.  
  6920.  
  6921.  
  6922.  
  6923.  
  6924.  
  6925.  
  6926.                                       101
  6927.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  6928.  
  6929.  
  6930.  
  6931.  
  6932.  
  6933.  
  6934.  
  6935.  
  6936.  
  6937.                                 EVENT TRAPPING
  6938.                                 --------------
  6939.  
  6940.          Additional library files have been included which allow event
  6941.          trapping ( SEE THE SECTION TITLED FILES ).
  6942.  
  6943.          These libraries may be used for programs which do not require
  6944.          event trapping also.  It is important to note, however, that
  6945.          additional code will be added to programs that are compiled from
  6946.          the QB/QBX/VBDOS environments, even if event trapping is not
  6947.          used.
  6948.  
  6949.          QuickBASIC 4.5, BASIC 7.1, and VBDOS detect event trapping
  6950.          capabilities in the *.QLB library and add the /W or /V switch to
  6951.          the compiler ( BC.EXE )  when modules are compiled from the
  6952.          programming environment; even if the modules do not use event
  6953.          trapping.  This adds extra code to the program and reduces it's
  6954.          speed.   If modules not are compiled and linked from the command
  6955.          line the /W and /V switches are not required for modules not
  6956.          using event trapping.  If modules will be compiled from the
  6957.          programming environment and event trapping is not used, use the
  6958.          libraries supplied which do not include event trapping.  THESE
  6959.          LIBRARIES ARE NOT SUPPLIED IN THE UNENHANCED VERSIONS.
  6960.  
  6961.          When event trapping is used care should be taken to assure that
  6962.          "exit keys" for routines do not conflict with keys trapped via
  6963.          event ( key ) trapping.  For example if the F1 key is used as an
  6964.          "exit key" for routine MULTINPT and the F1 key is trapped via
  6965.          event trapping two events will occur.  The event trapping routine
  6966.          will be executed for the F1 key pressed event, and routine
  6967.          MULTINPT will be executed as F1 is designated as an "exit key".
  6968.  
  6969.  
  6970.  
  6971.  
  6972.  
  6973.  
  6974.  
  6975.  
  6976.  
  6977.  
  6978.  
  6979.  
  6980.  
  6981.  
  6982.  
  6983.  
  6984.  
  6985.  
  6986.  
  6987.  
  6988.  
  6989.  
  6990.  
  6991.  
  6992.                                       102
  6993.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  6994.  
  6995.  
  6996.  
  6997.  
  6998.  
  6999.  
  7000.  
  7001.  
  7002.  
  7003.                                      FILES
  7004.  
  7005.               The following files are included with WINDOWS R-E-Z.
  7006.           The files included depend on the version you have received.
  7007.           Some files are for QuickBASIC 4.5, some are for BASIC 7.1,
  7008.           while others are for Visual BASIC for DOS.
  7009.  
  7010.           Library Files:
  7011.  
  7012.           - Library consisting of all assembly procedures.
  7013.  
  7014.            *  QBASM.LIB ---- For QuickBASIC 4.5
  7015.            *  PDSASM.LIB --  For BASIC 7.1
  7016.            *  VBASM.LIB  --  For Visual BASIC for DOS
  7017.  
  7018.           - QB/QBX/VBDOS assembly procedure quick libraries.
  7019.  
  7020.            *  QBASM.QLB ---- For QuickBASIC 4.5
  7021.            *  PDSASM.QLB --- For BASIC 7.+
  7022.            *  VBASM.QLB ---- For Visual BASIC for DOS
  7023.  
  7024.           - Library consisting of all assembly and BASIC procedures.
  7025.  
  7026.            *  QBALL.LIB ---- For QuickBASIC 4.5
  7027.            *  PDSALL.LIB --- For BASIC 7.1
  7028.            *  VBALL.LIB ---- For Visual BASIC for DOS
  7029.            *  QBTRAP.LIB --- For QB 4.5      ( allows event trapping )
  7030.            *  PDSTRAP.LI --- For BASIC 7.1   ( allows event trapping )
  7031.            *  VBTRAP,LIB --- For VB for DOS  ( allows event trapping )
  7032.           **  QBUNEN.LIB --- For QuickBASIC 4.5         ( unenhanced )
  7033.           **  PDSUNEN.LIB -- For BASIC 7.1              ( unenhanced )
  7034.           **  VBUNEN.LIB --- For Visual BASIC for DOS   ( unenhanced )
  7035.  
  7036.           - QB/QBX/VBDOS assembly and BASIC quick libraries.
  7037.  
  7038.            *  QBALL.QLB ---- For QuickBASIC 4.50
  7039.            *  PDSALL.QLB --- For BASIC 7.1
  7040.            *  VBALL.QLB ---- For Visual BASIC for DOS
  7041.            *  QBTRAP.QLB --- For QB 4.5      ( allows event trapping )
  7042.            *  PDSTRAP.QLB -- For BASIC 7.1   ( allows event trapping )
  7043.            *  VBTRAP.QLB --- For VB for DOS  ( allows event trapping )
  7044.           **  QBUNEN.QLB --- For QuickBASIC 4.5         ( unenhanced )
  7045.           **  PDSUNEN.QLB -- For BASIC 7.1              ( unenhanced )
  7046.           **  VBUNEN.QLB --- For Visual BASIC for DOS   ( unenhanced )
  7047.  
  7048.  
  7049.  
  7050.  
  7051.  
  7052.  
  7053.            * Not included with the unenhanced version of WINDOWS R-E-Z.
  7054.           ** Not included with the enhanced version of WINDOWS R-E-Z.
  7055.  
  7056.  
  7057.  
  7058.                                       103
  7059.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  7060.  
  7061.  
  7062.  
  7063.  
  7064.  
  7065.  
  7066.  
  7067.  
  7068.  
  7069.           - Library of all assembly and BASIC procedures without
  7070.             error detection or window status.  Program MUST be
  7071.             completely "debugged" before these are used.
  7072.  
  7073.            *  QBNER.LIB ---- For QuickBASIC 4.50
  7074.            *  PDSNER.LIB --- For BASIC 7.1
  7075.            *  VBNER.LIB ---- For Visual BASIC for DOS
  7076.            *  QBNETRP.LIB ---- For QB 4.50        ( allows event trapping )
  7077.            *  PDSNETRP.LIB --- For BASIC 7.1      ( allows event trapping )
  7078.            *  VBNETRP.LIB ---- For VB for DOS     ( allows event trapping )
  7079.  
  7080.           - QB/QBX/VBDOS no error quick libraries.
  7081.  
  7082.            *  QBNER.QLB ---- For QuickBASIC 4.50
  7083.            *  PDSNER.QLB --- For BASIC 7.1
  7084.            *  VBNER.QLB ---- For Visual BASIC for DOS
  7085.            *  QBNETRP.QLB ---- For QB 4.50        ( allows event trapping )
  7086.            *  PDSNETRP.QLB --- For BASIC 7.1      ( allows event trapping )
  7087.            *  VBNETRP.QLB ---- For VB for DOS     ( allows event trapping )
  7088.  
  7089.           Object Files:
  7090.  
  7091.            QB*.OBJ = QuickBASIC 4.5, PDS*.OBJ = BASIC 7.1, VB*.OBJ = VB DOS
  7092.  
  7093.            *  QBWIND.OBJ --- Object file of assembly windowing
  7094.            *  PDSWIND.OBJ    routines.
  7095.            *  VBWIND.OBJ     "                                    "
  7096.            *  QBINPT.OBJ --- Object file of assembly input routines.
  7097.            *  PDSINPT.OBJ    "                                    "
  7098.            *  VBINPT.OBJ     "                                    "
  7099.            *  QBDIR.OBJ ---- Object file of assembly directory
  7100.            *  PDSDIR.OBJ     routines.
  7101.            *  VBDIR.OBJ      "                                    "
  7102.            *  QBSCRL.OBJ --- Object file of assembly scroll
  7103.            *  PDSSCRL.OBL    routines
  7104.            *  VBSCRL.OBJ     "                                    "
  7105.            *  PDSALT.OBJ     Alternate memory management object file
  7106.            *  VBALT.OBJ      "                                    "
  7107.  
  7108.           Basic Files:
  7109.  
  7110.            *  INPTWIND.BAS - BASIC source code for routines in
  7111.            *  PULLDOWN.BAS   WINDOWS R-E-Z.
  7112.            *  SCROLL.BAS           "
  7113.            *  WIND_REZ.BAS         "
  7114.            *  DIRWIND.BAS          "
  7115.            *  QBMEM.BAS                  ( QuickBASIC 4.5 )
  7116.            *  PDSVBMEM.BAS               ( BASIC 7.1 / VBDOS )
  7117.  
  7118.  
  7119.            * Not included with the unenhanced version of WINDOWS R-E-Z.
  7120.           ** Not included with the enhanced version of WINDOWS R-E-Z.
  7121.  
  7122.  
  7123.  
  7124.                                       104
  7125.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  7126.  
  7127.  
  7128.  
  7129.  
  7130.  
  7131.  
  7132.  
  7133.  
  7134.  
  7135.          Demonstration files.
  7136.  
  7137.               DEMO.BAS ----- Source code for demonstration program.
  7138.               DEMPART2.BAS   Part two of demonstration program.
  7139.               MULTSAM1.BAS   Sample multi-field input program.
  7140.               MULTSAM2.BAS         "
  7141.               MULTSAM3.BAS         "
  7142.               SCRLRAND.BAS   Scroll through a random access file.
  7143.               MAKERAND.BAS   Sample random access database.
  7144.               SCRLISAM.BAS   Scroll through an ISAM table.
  7145.               MAKEISAM.BAS   Sample ISAM data file.
  7146.  
  7147.            NOTE:  All BASIC files except QBMEM.BAS, PDSMEM.BAS and
  7148.            VBMEM,BAS are the same for QuickBASIC 4.5, BASIC 7.1, and
  7149.            VBDOS.  All basic routines require the presence of the module
  7150.            WIND_REZ.BAS INPTWIND.BAS and ***MEM.BAS
  7151.  
  7152.           Other Files:
  7153.  
  7154.           **  WIND_REZ.DOC - This document.
  7155.            *  WIND_REZ.EXE - Self-extracting compressed documentation.
  7156.                              Un-compresses to WIND_REZ.DOC.
  7157.               SCRLFILE.DOC - Scroll through file documentation.
  7158.               DEMO.EXE ----- Demonstration program.
  7159.               PRNTDOT.BAT -- Batch file for printing WIND_REZ.DOC.
  7160.               PRNTLAS.BAT -- Batch file for printing WIND_REZ.DOC on a
  7161.                              HP compatible laser printer.
  7162.               DECLARE.INC -- INCLUDE file containing DECLARE
  7163.                              statements for all routines.
  7164.               ORDER.ME ----- Order form for WINDOWS R-E-Z.
  7165.               READ.ME  ----- Update information.
  7166.            *  QUICKREF.DOC - Quick reference guide.
  7167.            *  PRNTDOT2.BAT - Batch file for printing QUICKREF.DOC.
  7168.            *  PRNTLAS2.BAT - Batch file for printing QUICKREF.DOC on a
  7169.                              HP compatible laser printer.
  7170.  
  7171.  
  7172.  
  7173.  
  7174.  
  7175.  
  7176.  
  7177.  
  7178.  
  7179.  
  7180.  
  7181.  
  7182.  
  7183.  
  7184.  
  7185.            * Not included with the unenhanced version of WINDOWS R-E-Z.
  7186.           ** Not included with the enhanced version of WINDOWS R-E-Z.
  7187.  
  7188.  
  7189.  
  7190.                                       105
  7191.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  7192.  
  7193.  
  7194.  
  7195.  
  7196.  
  7197.  
  7198.  
  7199.  
  7200.  
  7201.                                     Errors
  7202.  
  7203.           The following is a listing of the errors WINDOWS R-E-Z
  7204.           will detect.
  7205.  
  7206.           ERROR #       DESCRIPTION
  7207.           ------------------------------------------------------------
  7208.  
  7209.           ERROR 1       There is no active window.  SCRLWIND, RESAVE
  7210.                         CLRWIND, PRINTW, PRINTWHOT, LINEW, NEWCOLOR,
  7211.                         and BOXW require an active window.
  7212.  
  7213.  
  7214.           ERROR 2       SETWIND has not been called to initialize
  7215.                         window memory.  This error will also be reported
  7216.                         if the program uses a CLEAR statement and SETWIND
  7217.                         has not be called to re-initialize window
  7218.                         memory.
  7219.  
  7220.  
  7221.           ERROR 3       A window number has been specified which is
  7222.                         out of range for the calling routine.  Window
  7223.                         number 20 is the maximum window number for all
  7224.                         routines.  Window number 1 is the minimum
  7225.                         window number for SAVEWIND, DELWIND, RESAVE
  7226.                         and RSTRWIND.  Window number 0 is the minimum
  7227.                         window number for MAKEWIND and CHNGWIND.
  7228.  
  7229.  
  7230.           ERROR 4       The window will not fit on the screen or the
  7231.                         window is too small.  The left column plus the
  7232.                         window's width makes the window too wide or the
  7233.                         top row plus the number of rows makes the
  7234.                         window too tall.  The left column and top row
  7235.                         must be greater than 0.  The width and number
  7236.                         of rows must be greater than 2.  The left column
  7237.                         or row are out of permissible range.
  7238.  
  7239.                         GETANS makes a window with a width predicated
  7240.                         on the width of the prompt.
  7241.  
  7242.                         INPTWIND makes a window with a width based on
  7243.                         the length of the prompt plus the width of the
  7244.                         input field.  Input windows with < OK > and
  7245.                         < CANCEL > buttons require additional rows.
  7246.  
  7247.                         PULLDOWN windows have a width based on the
  7248.                         longest item in the pulldown window's list.
  7249.                         The number or rows in a pulldown window are
  7250.                         based on the number of selections and segmenting
  7251.                         lines in same.
  7252.  
  7253.  
  7254.  
  7255.  
  7256.                                       106
  7257.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  7258.  
  7259.  
  7260.  
  7261.  
  7262.  
  7263.  
  7264.  
  7265.  
  7266.  
  7267.                         CHOICEWIND makes a window with a width based
  7268.                         on the longest line of text in it or the width of
  7269.                         the choices in it.  The length is based on the
  7270.                         number of lines of text in the choice window.
  7271.  
  7272.                         This error is reported for INPTWIND and GETANS
  7273.                         if no window is specified ( BORDER%=0 ) and the
  7274.                         width of the prompt and/or field will not fit on
  7275.                         the screen.
  7276.  
  7277.  
  7278.           ERROR 5       The border designation is not valid for the
  7279.                         calling routine.  GETANS does not allow title
  7280.                         windows.  PULLDOWN does not allow title
  7281.                         windows and only allows right-bottom shadows.
  7282.                         SEE THE BORDER DESIGNATION CHART.
  7283.  
  7284.  
  7285.           ERROR 6       A request was made to CHNGWIND to make the
  7286.                         active window a non-existent window or a
  7287.                         window saved via SAVEWIND.  The active window
  7288.                         can only be a window generated by MAKEWIND.
  7289.  
  7290.  
  7291.           ERROR 8       An window specified in a call to MAKEWIND or
  7292.                         SAVEWIND previously existed.  A window must be
  7293.                         deleted via a call to DELWIND or RSTRWIND
  7294.                         before the number assigned to it can be used
  7295.                         again.  This error will not be reported for
  7296.                         window number 0 as it is not saved.
  7297.  
  7298.  
  7299.           ERROR 9       A call to INPTINIT was not made to initialize
  7300.                         input memory.  INPTINIT must be called once in
  7301.                         every program prior to calling routines INPTWIND
  7302.                         MULTINPT, CHOICEWIND, CHOICEBAR or SCRLWIND with
  7303.                         buttons.  If a CLEAR statememt is executed,
  7304.                         INPTINIT must be called again.
  7305.  
  7306.  
  7307.           ERROR 11      A bad row number was specified in a call to
  7308.                         PRINTW, PRINTWHOT, LINEW or BOXW.  The row
  7309.                         number must be greater than 0.  PRINTW and
  7310.                         PRINTWHOT allow print on the bottom border.
  7311.                         LINEW does not.  The string specified in a call
  7312.                         to PRINTW or PRINTWHOT will not fit in the
  7313.                         window due to it's length or it's left column
  7314.                         ( start print ) position.  The entire box in a
  7315.                         call to BOXW will not fit in the active window.
  7316.                         BOXW does not allow row or column value to
  7317.                         equal 100 to center then box.
  7318.  
  7319.  
  7320.  
  7321.  
  7322.                                       107
  7323.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  7324.  
  7325.  
  7326.  
  7327.  
  7328.  
  7329.  
  7330.  
  7331.  
  7332.  
  7333.           ERROR 12      The position or width of the info-line in a call
  7334.                         to INFOLINE or PRINTINFO is illegal.
  7335.  
  7336.                         The position or width of the menubar in a call
  7337.                         to SETPULL or PULLDOWN is illegal.
  7338.  
  7339.                         The position or width of the choicebar in a call to
  7340.                         CHOICEBAR is illegal.
  7341.  
  7342.                         The left column position is out of range.  A
  7343.                         combination of the left column position plus the
  7344.                         specified width will not allow the info-line,
  7345.                         menubar or choicebar to fit on one line.  The
  7346.                         menubar selection or choicebar selections will
  7347.                         not fit in the specified width.  The minimum row
  7348.                         position, left column position and left column
  7349.                         plus the width are checked on the calls to INFOLINE
  7350.                         SETPULL, and CHOICEBAR.  The maximum row position
  7351.                         is checked on the calls to PRINTINFO, PULLDOWN and
  7352.                         CHOICEBAR and is based on the active number of
  7353.                         display rows at the time of the call.
  7354.  
  7355.  
  7356.           ERROR 13      This is an array dimension error.
  7357.  
  7358.                         The array ( LIST$() ) in a call to SCRLWIND
  7359.                         has a lower dimension greater than 1 or an
  7360.                         upper dimension less then the number of entries
  7361.                         ( ENTRIES% ) in the list.
  7362.  
  7363.                         The array ( RTRN$() ) specified in a call to
  7364.                         MULTINPT has a lower dimension of greater than
  7365.                         one or an upper dimension less than the number
  7366.                         of fields in the multi-field input screen.
  7367.  
  7368.  
  7369.           ERROR 14      A routine was called with an illegal number of
  7370.                         selections.
  7371.  
  7372.                         The number of entries ( selections ) in a call
  7373.                         to SCRLWIND must be greater than one.
  7374.  
  7375.                         The number of selections in an "EXTENDED" scroll
  7376.                         window exceeds the number or interior rows in the
  7377.                         scroll window.
  7378.  
  7379.                         The number of selections in a pulldown window's
  7380.                         menubar, set by routine SETPULL must equal one to
  7381.                         ten.  Routine SETPULL attempted to make a pulldown
  7382.                         window with no selections in same.  This consecutive
  7383.                         "***"'s may be in the data stream.
  7384.  
  7385.  
  7386.  
  7387.  
  7388.                                       108
  7389.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  7390.  
  7391.  
  7392.  
  7393.  
  7394.  
  7395.  
  7396.  
  7397.  
  7398.  
  7399.                         The number of choices in a call to CHOICEWIND or
  7400.                         CHOICEBAR must equal one to ten.
  7401.  
  7402.  
  7403.           ERROR 15      The minimum size of a scroll window when routine
  7404.                         SCRLWIND is called not wide enough or does not
  7405.                         contain enough rows.  The size varies if < OK >
  7406.                         and < CANCEL > buttons are used. See the descrip-
  7407.                         tion for routine SCRLWIND for details.
  7408.  
  7409.  
  7410.           ERROR 16      At least one of the strings in the list for a
  7411.                         scroll window ( SCRLWIND ) will not fit in the
  7412.                         window, allowing for a space on either side of
  7413.                         the string. ( non-virtual scroll windows only )
  7414.  
  7415.  
  7416.           ERROR 21      The screen number specified in a call to SETINPT,
  7417.                         MAKEFIELD, or MULTINPT does not equal one to 10.
  7418.  
  7419.                         The screen number specified in a call to MULTINPT
  7420.                         or MAKEFIELD has not been defined by a previous
  7421.                         call to SETINPT.  MULTINPT has been called with
  7422.                         no fields previously defined by MAKEFIELD.
  7423.  
  7424.  
  7425.           ERROR 22      A bad field number has been specified.
  7426.  
  7427.                         Routine MAKEFIELD may use field numbers one to
  7428.                         150.  The field, however, must not be greater than
  7429.                         the highest previously defined field number plus
  7430.                         one.
  7431.  
  7432.                         The TOFLD% argument in a call to MULTINPT is
  7433.                         attempting to access a field which does not exist
  7434.                         for the specified MULTI-FIELD input screen
  7435.  
  7436.                         The FROMFLD% argument in a call to MULTINPT does
  7437.                         not equal zero or a valid field number for the
  7438.                         specified MULTI-FIELD input screen.
  7439.  
  7440.  
  7441.           ERROR 23      The color of a field in a call to INPTWIND or
  7442.                         MAKEFIELD equals zero.  This includes the field's
  7443.                         inactive color, active color, or mouse active
  7444.                         color in a call to MAKEFIELD.
  7445.  
  7446.  
  7447.  
  7448.  
  7449.  
  7450.  
  7451.  
  7452.  
  7453.  
  7454.                                       109
  7455.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  7456.  
  7457.  
  7458.  
  7459.  
  7460.  
  7461.  
  7462.  
  7463.  
  7464.  
  7465.           ERROR 24      The field code in INPTWIND does not consist of
  7466.                         legal characters. ("0","1","2","3","4","5","6",
  7467.                          "A","L","U","D","P0","P1","P2","P3","P4","P5,
  7468.                         "P6, "R" or "RP" )
  7469.  
  7470.                         The field code in a call to MAKEFIELD is illegal.
  7471.                         SEE THE FIELD CODE CHART IN THE APPENDIX.
  7472.  
  7473.  
  7474.           ERROR 25      The requested width of in input field in
  7475.                         INPTWIND or MAKEFIELD is out of range.  The
  7476.                         maximum width is 15 for numeric fields. The
  7477.                         minimum width for a numeric field, 0 to 6
  7478.                         decimal places, is the number decimal places
  7479.                         plus one.  The width for a date field must be
  7480.                         eight or ten.  The minimum width for a alpha-
  7481.                         numeric field is one. The maximum width is
  7482.                         79.  The maximum width for windowed fields in
  7483.                         routine INPTWIND depends on the windows
  7484.                         location, and the use of buttons.
  7485.  
  7486.  
  7487.           ERROR 26      The left column position plus the width of a
  7488.                         field defined in a call to MAKEFIELD will not
  7489.                         allow the field to fit on the screen.  The row
  7490.                         or column position is less than one.  The row
  7491.                         position of a field is greater than the display
  7492.                         length specified by the previous call to
  7493.                         SETINPT.
  7494.  
  7495.  
  7496.           ERROR 27      The number of characters in a restrict string
  7497.                         for an individual field defined in a call to
  7498.                         MAKEFIELD is greater than 255.
  7499.  
  7500.  
  7501.           ERROR 28      The cumulative total of restrict characters
  7502.                         for all fields for a multi-field input screen
  7503.                         defined via MAKEFIELD is greater than 1023.
  7504.  
  7505.  
  7506.           ERROR 29      The screen length when MULTINPT was called was
  7507.                         not the same as specified when the multi-field
  7508.                         input screen was defined by SETINPT.
  7509.  
  7510.                         The screen length specified in a call to SETINPT
  7511.                         was not 25, 43, or 50.
  7512.  
  7513.  
  7514.           ERROR 30      All fields defined by MAKEFIELD are protected
  7515.                         fields.  No input is possible.  This error is
  7516.                         detected when MULTINPT is called.
  7517.  
  7518.  
  7519.  
  7520.                                       110
  7521.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  7522.  
  7523.  
  7524.  
  7525.  
  7526.  
  7527.  
  7528.  
  7529.  
  7530.  
  7531.                                   APPENDIX I
  7532.                             Color Attribute Chart
  7533.  
  7534.           ATTRIBUTE                  BACKGROUND            FOREGROUND
  7535.  
  7536.           START     END
  7537.  
  7538.           0  ------ 15               BLACK                  NORMAL
  7539.           16 ------ 31               BLUE                   NORMAL
  7540.           32 ------ 47               GREEN                  NORMAL
  7541.           48 ------ 63               CYAN                   NORMAL
  7542.           64 ------ 79               RED                    NORMAL
  7543.           80 ------ 95               MAGENTA                NORMAL
  7544.           96 ------ 111              BROWN                  NORMAL
  7545.           112 ----- 127              LIGHT GRAY             NORMAL
  7546.           128 ----- 143              BLACK                  FLASHING
  7547.           144 ----- 159              BLUE                   FLASHING
  7548.           160 ----- 175              GREEN                  FLASHING
  7549.           176 ----- 191              CYAN                   FLASHING
  7550.           192 ----- 207              RED                    FLASHING
  7551.           208 ----- 223              MAGENTA                FLASHING
  7552.           224 ----- 239              BROWN                  FLASHING
  7553.           240 ----- 255              LIGHT GRAY             FLASHING
  7554.           -----------------------------------------------------------
  7555.           OFFSET FROM START                                 FOREGROUND
  7556.  
  7557.           0                                                 BLACK
  7558.           1                                                 BLUE
  7559.           2                                                 GREEN
  7560.           3                                                 CYAN
  7561.           4                                                 RED
  7562.           5                                                 MAGENTA
  7563.           6                                                 BROWN
  7564.           7                                                 LIGHT GRAY
  7565.           8                                                 DARK GRAY
  7566.           9                                                 LIGHT BLUE
  7567.           10                                                LIGHT GREEN
  7568.           11                                                LIGHT CYAN
  7569.           12                                                LIGHT RED
  7570.           13                                                LIGHT MAGENTA
  7571.           14                                                YELLOW
  7572.           15                                                WHITE
  7573.  
  7574.  
  7575.           EXAMPLE: If the attribute = 242 then the background color is
  7576.                    light gray and the foreground flashes.  The offset
  7577.                    from start = 242 - 240 or 2, so the foreground color
  7578.                    is green.
  7579.  
  7580.           NOTE: GETANS and SCRLWIND allow a flashing border only.
  7581.           CHNGPULL, PULLDOWN, AND MULTINPT will not allow a flashing
  7582.           border or text.
  7583.  
  7584.  
  7585.  
  7586.                                       111
  7587.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  7588.  
  7589.  
  7590.  
  7591.  
  7592.  
  7593.  
  7594.  
  7595.  
  7596.  
  7597.                                    APPENDIX II
  7598.                              MAKEFIELD code chart
  7599.  
  7600.           The code for each field can be up to five digits long.  The
  7601.           digits are numbered 5,4,3,2 and 1, with 1 being the least
  7602.           significant digit and 5 the most significant digit.
  7603.  
  7604.           DIGIT NUMBER -------  5  4  3  2  1
  7605.  
  7606.           EXAMPLE CODE% ------  2  1  0  1  6
  7607.  
  7608.           - Digits 1 and 2 set the field type and can be:
  7609.  
  7610.           00  ------ Numeric - no decimal places.
  7611.           01 to 06 - Numeric - 1 to 6 decimal places
  7612.           10 ------- Numeric - no decimal places - padded with leading
  7613.                      zeros.
  7614.           11 to 16 - Numeric - 1 to 6 decimal places - padded with
  7615.                      leading zeros.
  7616.           30 ------- Numeric - real number.
  7617.           40 ------- Numeric - real number - padded with leading zeros.
  7618.  
  7619.           07 ------- Alpha/numeric
  7620.           17 ------- Alpha/numeric -- UPPER CASE
  7621.           27 ------- Alpha/numeric -- lower case
  7622.  
  7623.           08 ------- Date   ( Type determined by call to INPTINIT. )
  7624.  
  7625.           - Digit 3 sets a protected field ( No entry ) and can be:
  7626.  
  7627.           0 -------- Field is NOT protected.
  7628.           1 -------- Field is protected. ( or "mouse only selectable" )
  7629.  
  7630.           - Digit 4 sets an Auto-advance field and can be:
  7631.  
  7632.           0 -------- Field is NOT Auto-advance.
  7633.           1 -------- Field is Auto-advance.
  7634.  
  7635.           - Digit ---- 5 sets an Auto-exit field and can be:
  7636.  
  7637.           0 -------- Field is NOT Auto-exit.
  7638.           1 -------- Field is Auto-exit.
  7639.           3 -------- Field is Fixed-choice. ( also auto-exit  ). Use
  7640.                      for buttons, fixed choice, or "mouse selectable".
  7641.  
  7642.           EXAMPLE: IF CODE% = 11016 the field is decimal with padded
  7643.                    zero's, Auto-advance, and Auto-exit.
  7644.  
  7645.           NOTE: If digit 3 is set to 1 (protected) digits 4 and 5 are
  7646.                 ignored. EXCEPTION: If the field code = 30100 the field
  7647.                 is a "mouse only selectable field"
  7648.  
  7649.  
  7650.  
  7651.  
  7652.                                       112
  7653.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  7654.  
  7655.  
  7656.  
  7657.  
  7658.  
  7659.  
  7660.  
  7661.  
  7662.  
  7663.                                   APPENDIX III
  7664.  
  7665.                                Border Designations
  7666.  
  7667.         DIGIT NUMBER         3    2    1
  7668.         EXAMPLE BORDER%      1    2    1       ( 121 )
  7669.  
  7670.         Digit 1 = Border     Digit 2 = Shadow   Digit 3 = Title Box
  7671.  
  7672.         Example (121) = title box/ left bottom shadow/ single line border
  7673.         ------------------------------------------------------------------
  7674.                     :---Border---:          :------- Shadow -----------:
  7675.           Border    Single  Double   Title  Right   Left    Left  Right
  7676.           Value     Line    Line     Box    Bottom  Bottom  Top   Top
  7677.  
  7678.               0            No border, title box, or shadow
  7679.               1     X
  7680.               2             X
  7681.              10                              X
  7682.              11     X                        X
  7683.              12             X                X
  7684.              20                                     X
  7685.              21     X                               X
  7686.              22             X                       X
  7687.              30                                             X
  7688.              31     X                                       X
  7689.              32             X                               X
  7690.              40                                                    X
  7691.              41     X                                              X
  7692.              42             X                                      X
  7693.  
  7694.             100                       X
  7695.             101     X                 X
  7696.             102             X         X
  7697.             110                       X      X
  7698.             111     X                 X      X
  7699.             112             X         X      X
  7700.             120                       X             X
  7701.             121     X                 X             X
  7702.             122             X         X             X
  7703.             130                       X                     X
  7704.             131     X                 X                     X
  7705.             132             X         X                     X
  7706.             140                       X                            X
  7707.             141     X                 X                            X
  7708.             142             X         X                            X
  7709.           -------------------------------------------------------------------
  7710.           See individual routines for restrictions.
  7711.  
  7712.  
  7713.  
  7714.  
  7715.  
  7716.  
  7717.  
  7718.                                       113
  7719.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  7720.  
  7721.  
  7722.  
  7723.  
  7724.  
  7725.  
  7726.  
  7727.  
  7728.  
  7729.                                APPENDIX IV
  7730.  
  7731.                            GETAKEY CODE VALUES
  7732.  
  7733.           GETAKEY%       Key(s)
  7734.  
  7735.           1 to 255       The equivalent key which produces the
  7736.                          corresponding ASCII/IBM code.
  7737.                          ( 65 = A, 66 = B etc. )
  7738.  
  7739.           15104          F1
  7740.           15360          F2
  7741.           15616          F3
  7742.           15872          F4
  7743.           16128          F5
  7744.           16384          F6
  7745.           16640          F7
  7746.           16896          F8
  7747.           17152          F9
  7748.           17408          F10
  7749.           18432          UP ARROW
  7750.           20480          DOWN ARROW
  7751.           19200          LEFT ARROW
  7752.           19712          RIGHT ARROW
  7753.           18688          PGUP
  7754.           20736          PGDN
  7755.           18176          HOME
  7756.           20224          END
  7757.           20992          INSERT
  7758.           21248          DELETE
  7759.           29952          CTRL-END
  7760.           30464          CTRL-HOME
  7761.  
  7762.           NOTE: THIS LIST IS NOT ALL INCLUSIVE.  IT DOES PROVIDE
  7763.           VALUES FOR COMMON KEYS OR KEY COMBINATIONS.
  7764.  
  7765.           To find the values for other keys or key combinations this
  7766.           small program can be used.  Press ESC to end the program.
  7767.  
  7768.           DECLARE FUNCTION GETAKEY%%
  7769.  
  7770.           DO
  7771.             DO
  7772.               A%= GETAKEY%
  7773.             LOOP WHILE A% = 0
  7774.             PRINT A%
  7775.           LOOP WHILE A% <> 27
  7776.           END
  7777.  
  7778.           As a key or key combination is pressed the corresponding
  7779.           value will print on the screen.
  7780.  
  7781.  
  7782.  
  7783.  
  7784.                                       114
  7785.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  7786.  
  7787.  
  7788.  
  7789.  
  7790.  
  7791.  
  7792.  
  7793.  
  7794.  
  7795.                                  RESTRICTIONS
  7796.  
  7797.           ------------------------------------------------------------
  7798.                               UNENHANCED LIBRARY
  7799.  
  7800.                    THE UNENHANCED LIBRARY IS OFFERED ON A TRIAL BASIS.
  7801.            IT MAY BE USED FOR EVALUATION.  EXECUTABLE PROGRAMS MADE
  7802.            FROM THE UNENHANCED LIBRARY MAY NOT BE DISTRIBUTED.  IF YOU
  7803.            DECIDE THE ROUTINES ARE USEFUL, REGISTRATION MAY BE
  7804.            ACCOMPLISHED BY VIRTUE OF SECURING THE ENHANCED VERSION.
  7805.            THE UNENHANCED LIBRARY MAY NOT BE ALTERED.  THE UNENHANCED
  7806.            LIBRARY MAY BE DISTRIBUTED, PROVIDED IT IS DISTRIBUTED WITH
  7807.            ALL OF THE FILES INCLUDED IN QWEZ60.ZIP, PWEZ60.ZIP OR
  7808.            VWEZ60.ZIP.
  7809.  
  7810.                   THE FILES, QWEZ60.ZIP, PWEZ60.ZIP, OR VWEZ60.ZIP MAY BE
  7811.            UP-LOADED IN THEIR ENTIRETY TO ANY PUBLIC OR PRIVATE BULLETIN
  7812.            BOARD.  INDIVIDUAL FILES NOT BE UP-LOADED.
  7813.  
  7814.           ------------------------------------------------------------
  7815.                                 ENHANCED VERSION
  7816.  
  7817.                  ALL OF THE SOURCE CODE, OBJECT CODE, AND LIBRARIES
  7818.            INCLUDED IN WINDOWS R-E-Z IS COPYRIGHTED.  COPYING AND
  7819.            DISTRIBUTING ANY OF THE MATERIAL IS PROHIBITED.  PROGRAMS
  7820.            MADE USING ANY OF THE PROCEDURES FROM WINDOWS R-E-Z IN THE
  7821.            EXECUTABLE (.EXE ) FORM MAY BE DISTRIBUTED FREELY BY
  7822.            ORIGINAL PURCHASERS.
  7823.  
  7824.           ------------------------------------------------------------
  7825.                                 COPYRIGHT WARNING
  7826.  
  7827.                  EXTRANEOUS CODE HAS BEEN INSERTED IN THE LIBRARY
  7828.            FILES.   ANY PROGRAM MADE USING THE LIBRARY FILES IS
  7829.            DISTINGUISHABLE AS ORIGINATING FROM WINDOWS R-E-Z.  CONNECT
  7830.            SOFTWARE WILL TAKE APPROPRIATE ACTION IF COPYRIGHT
  7831.            INFRINGEMENT IS DISCOVERED.
  7832.  
  7833.           ------------------------------------------------------------
  7834.                                    DISCLAIMER
  7835.  
  7836.               ANY LOSS INCURRED FROM THE USE OF THE PROCEDURES CON-
  7837.           TAINED IN WINDOWS R-E-Z, OR ANY LOSS BELIEVED TO BE CAUSED
  7838.           FROM THE PROCEDURES CONTAINED IN WINDOWS R-E-Z IS NOT THE
  7839.           RESPONSIBILITY OF CONNECT SOFTWARE.  USERS OF WINDOWS R-E-Z
  7840.           ASSUME FULL RESPONSIBILITY FOR THE USE OF ANY PROCEDURES
  7841.           CONTAINED WITHIN.
  7842.           ------------------------------------------------------------
  7843.  
  7844.  
  7845.  
  7846.  
  7847.  
  7848.  
  7849.  
  7850.                                       115
  7851.        Copyright(c) 1988-92 - By: CONNECT Software - All rights reserved.
  7852.  
  7853.  
  7854.  
  7855.