home *** CD-ROM | disk | FTP | other *** search
/ Software of the Month Club 1995 December / SOFM_Dec1995.bin / pc / os2 / adeptbbs / adprexx.doc < prev    next >
Text File  |  1995-10-31  |  67KB  |  1,874 lines

  1.  
  2.  
  3.  
  4.        ----------------------------------------------------------------------
  5.  
  6.                                 AdeptXBBS REXX INTERFACE
  7.  
  8.  
  9.                          Copyright (c) 1993 - 1995 by AdeptSoft
  10.                        portions Copyright (c)  1991-1994 M. Kimes
  11.                                   All Rights Reserved
  12.  
  13.  
  14.        ----------------------------------------------------------------------                                                                             2
  15.  
  16.  
  17.  
  18.        ADEPT REXX INTERFACE ................................................4
  19.         Standard and Extended REXX Programs: ...............................5
  20.         Proper REXX Programming Syntax: ....................................6
  21.         Adept REXX Interface Calls: ........................................7
  22.           AdeptCall ........................................................7
  23.           AdeptChainRexx ...................................................9
  24.           AdeptChainRexxNc .................................................9
  25.           AdeptChangeGroup .................................................9
  26.           AdeptCheckBit ...................................................10
  27.           AdeptCls ........................................................10
  28.           AdeptComFlush ...................................................11
  29.           AdeptComWrite ...................................................11
  30.           AdeptConvert ....................................................12
  31.           AdeptDial .......................................................12
  32.           AdeptDoDTR ......................................................13
  33.           AdeptDropGlobalVar ..............................................13
  34.           AdeptFile .......................................................13
  35.           AdeptGetGlobalVar ...............................................14
  36.           AdeptGetVar and AdeptPutVar .....................................14
  37.           AdeptHitReturn ..................................................19
  38.           AdeptInKey ......................................................20
  39.           AdeptInput ......................................................20
  40.           AdeptLibrary ....................................................21
  41.           AdeptLocation ...................................................22
  42.           AdeptLog ........................................................22
  43.           AdeptMenu .......................................................23
  44.           AdeptMenuType ...................................................23
  45.           AdeptMessage ....................................................24
  46.           AdeptMore .......................................................25
  47.           AdeptPause ......................................................25
  48.           AdeptPeekByte ...................................................25
  49.           AdeptPrint ......................................................26
  50.           AdeptPrintL .....................................................26
  51.           AdeptPutC .......................................................26
  52.           AdeptPutKey .....................................................27
  53.           AdeptRead .......................................................27
  54.           AdeptRecv .......................................................28
  55.           AdeptRexxKillThread .............................................29
  56.           AdeptRexxStartThread ............................................29
  57.           AdeptSend .......................................................30
  58.           AdeptSetBit .....................................................31
  59.           AdeptSetGlobalVar ...............................................31                                                                             3
  60.  
  61.  
  62.           AdeptSetTimer ...................................................31
  63.           AdeptShow .......................................................32
  64.           AdeptSleep ......................................................32
  65.           AdeptTimedInKey .................................................33
  66.           AdeptTimeLeft ...................................................33
  67.           AdeptTimerUp ....................................................34
  68.           AdeptUnsetBit ...................................................34
  69.           AdeptWaitConnect ................................................35
  70.           AdeptWaitKey ....................................................35
  71.           AdeptWrite ......................................................36
  72.           AfSysAddIndexEntries ............................................36
  73.           AfSysClose ......................................................37
  74.           AfSysDeleteIndexEntries .........................................38
  75.           AfSysOpen .......................................................39
  76.           AfSysSetIndexAreaNumber .........................................41
  77.           AfSysSetIndexEntryDate ..........................................41
  78.           AfSysSetIndexFileName ...........................................41
  79.           AfSysSetIndexRecordOffset .......................................41
  80.        CTRL AND OTHER KEYS AND THEIR RETURN CODES: ........................45                                                                             4
  81.  
  82.  
  83.        ADEPT REXX INTERFACE
  84.  
  85.        AdeptXBBS comes with two 'menu' systems, the standard text, ASCII
  86.        based menu system and a REXX sub-system.  The REXX sub-system
  87.        included with the BBS software allows all basic menu functions with
  88.        some additional flexibility.
  89.  
  90.        We also offer, still in development, a complete REXX API sub-system
  91.        that gives even the novice programmer total control over the BBS
  92.        software.
  93.  
  94.        With the AdeptXBBS REXX API Programming module you get access to all
  95.        available memory variables,  all internal functions,  and complete
  96.        unrestricted access to all running nodes at one time.
  97.  
  98.        This is an extremely powerful module, giving total control over the
  99.        entire BBS.  For programmers wishing to write their own programs in
  100.        a simple language, yet maintain the speed and flexibility of AdeptXBBS
  101.        this is for you.  We also have utilities that allow you to ship your
  102.        programs without making the source code available to the end user.
  103.  
  104.        For more information about the REXX Programming module contact
  105.        AdeptSoft.
  106.  
  107.        Adept contains a REXX interface to the BBS functions.  This allows you
  108.        to create your own scripts to execute from Adept.  By using REXX
  109.        functions alone you can completely customize Adept.
  110.        Two types of REXX commands can be automatically executed by Adept. To
  111.        be executed they need only exist in the .\Menus directory.
  112.  
  113.        Main.Cmd or Main?.Cmd   -- This REXX script is executed INSTEAD OF
  114.                                    the default menu system.
  115.  
  116.        AtEnd.Cmd or AtEnd?.Cmd -- This REXX script is executed after the
  117.                                    user logs off (or the default script has
  118.                                    ended) The BPS rate will be zero and the
  119.                                    time left will be five minutes. This
  120.                                    script is executed before the user info is
  121.                                    saved to the user data base.
  122.  
  123.        AtStart.Cmd or
  124.        AtStart?.Cmd             -- This REXX script is executed at logon.
  125.                                    The filename with the line number is                                                                             5
  126.  
  127.  
  128.                                    executed in place of 'AtStart.Cmd' if it
  129.                                    exists.
  130.        Exception.Cmd            -- This REXX script is executed if a
  131.                                    exception violation occurs.  You can use
  132.                                    this script to notify the user of what
  133.                                    just happened.  And to help assist us by
  134.                                    asking the user what they where doing when
  135.                                    the exception happened.
  136.  
  137.  
  138.  
  139.        Standard and Extended REXX Programs:
  140.  
  141.        Several things will change in reference to the REXX system
  142.        in this next beta.  We will no longer run .CMD file.   We have
  143.        decided to call .CMD files .SRX (Standard REXX) files.  This
  144.        will pave the way for .ERX (Extended REXX) files.  .ERX files
  145.        are preprocessed REXX files for use with Adept.  Sysops who own
  146.        the REXX module will be able to execute .ERX files.  Sysops who
  147.        do not will ONLY be able to execute .SRX files.
  148.  
  149.        Why ERX files?
  150.  
  151.        ERX files are REXX files that have been preprocessed with the
  152.        AdeptREXX Processor (SrToErx).  ERX files are typically 50% smaller
  153.        and always faster then standard REXX files (When run Cached).
  154.  
  155.        We are asking that people who write rexx scripts for Adept that
  156.        are not pre-processed please use the extension .SRX.  The
  157.        preprocessor will ONLY process files with the .SRX extension.
  158.  
  159.        SrxToErx.Exe FileNameWithoutExtention will yield a file with the
  160.        same name, but the .ERX extension.  If you are a commercial
  161.        developer is recommended that you preprocess your rexx .SRX
  162.        files before distributing them.  Also it recommended that you
  163.        DO NOT preprocess the following!
  164.  
  165.        Atstart.Cmd - This MUST remain a .CMD file.  So that others may
  166.        modify it and chain needed rexx scripts (preprocessed or not) from
  167.        it.
  168.  
  169.        The BBS software will look for .ERX versions of files that we
  170.        feel are ok to pre-process.  In fact if you are running a .SRX                                                                             6
  171.  
  172.  
  173.        file (i.e. .cmd) file in cached mode (as we default to) it is
  174.        treated as a .ERX file after we preprocess it internally.  So
  175.        it is honestly recommended that you do not preprocess anything
  176.        that you are NOT going to be distributing.
  177.  
  178.        Proper REXX Programming Syntax:
  179.  
  180.        ALL REXX functions in the software unless you are looking for a value
  181.        should be called with the CALL function NOT with the () method.
  182.  
  183.        i.e.
  184.  
  185.        call AdeptChainRexx "RexxCmdFile.Cmd", line
  186.  
  187.        NOT - AdeptChainRexx("RexxCmdFile.Cmd", line)
  188.  
  189.        The second one will usually not work correctly.  The first works.
  190.  
  191.        Also you should try to use the call functioname ANY time you are
  192.        not get a value back i.e.
  193.  
  194.        call AdeptPrint line, "This is a line to print"
  195.  
  196.        key = AdeptWaitKey(line)                                                                             7
  197.  
  198.  
  199.        Adept REXX Interface Calls:
  200.  
  201.        Adept registers functions which can be called from the REXX
  202.        interpreter.
  203.        These calls are used to interface a REXX script to Adept.
  204.        When Adept starts a REXX script, it passes along the line number
  205.        as the first argument to the function.  The REXX script should store
  206.        that line number because it must be passed back to the AdeptREXX
  207.        functions as the first parameter.
  208.  
  209.        Remember to Start every REXX script with /* <text if any> */ then on
  210.        the next line (or the one after) Do the following ..
  211.  
  212.                 ARG Line
  213.                   *OR*
  214.                 ARG LineNumber
  215.  
  216.        Remember, if you use "Line", then all your REXX Function must have the
  217.        first parameter as "Line". If you use "LineNumber" then all your REXX
  218.        functions must have the first parameter as "LineNumber".
  219.        If you have used ARG Line and in a function you have put "LineNumber"
  220.        (where it's supposed to be) then nothing will happen :), so you must
  221.        remember to always use the same argument that you started with.
  222.  
  223.             ** Example **
  224.  
  225.        You used ARG Line so all your Functions (AdeptPrint, AdeptCall,
  226.        AdeptInput, etc..) will have to be passed like so ..
  227.  
  228.                call AdeptPrint Line,"String"
  229.  
  230.                    and NOT
  231.  
  232.                call AdeptPrint LineNumber, "String"
  233.  
  234.        It is the same if you have the two reversed. So really, where ever you
  235.        see "LineNumber" in this file, you replace it With the Argument you
  236.        Stated at the beginning of the REXX Script.
  237.  
  238.  
  239.  
  240.        AdeptCall
  241.        call AdeptCall LineNumber, Type, Flags, String1, ..., StringN                                                                             8
  242.  
  243.  
  244.        or
  245.        value = AdeptCall(LineNumber, Type, Flags, String1, ..., StringN)
  246.  
  247.          Runs an external program.
  248.  
  249.          LineNumber:
  250.             Line number. Passed to REXX routine from Adept as first
  251.             parameter.
  252.          Type:
  253.             1   Same as menu item 801. Spawn a separate session. Strings
  254.                 are concatenated to form one string which is used as the
  255.                 spawn string. Can be used for a door program that accesses
  256.                 the com port in a more traditional (and complicated) fashion.
  257.                 You can run DOS doors here also.
  258.                 Flags:
  259.                   1  Start session in background.
  260.  
  261.             2   Same as menu item 802. Run OS/2 type door.
  262.                 (same as menu item 800 but assumes a program which is more
  263.                 friendly to having its I/O redirected thru pipes to the com
  264.                 port.)  Program must allow itself to be killed.
  265.                 Flags:
  266.                   Not Used.
  267.             3   Same as menu item 800. Run OS/2 type door. Program must allow
  268.                 itself to be killed.
  269.                 Flags:
  270.                   Not Used.
  271.          Flags:
  272.             Only used for Type 1 call.  If flag is 1, then the program is
  273.             started in the background.
  274.          String1..N:
  275.             Strings are added together to form one string which is used to
  276.             spawn the session.
  277.  
  278.          Returns:
  279.             Return code from the spawning function.  0 usually indicates
  280.             success.
  281.  
  282.          All sessions inherit Adepts environment.
  283.  
  284.        ** Example **
  285.  
  286.            call AdeptCall Linenumber,1,,'cmd.exe /c twar.bat'                                                                             9
  287.  
  288.  
  289.  
  290.           This would call the batch file twar.bat and run TradeWars in the
  291.           Foreground.
  292.  
  293.  
  294.        AdeptChainRexx
  295.        call AdeptChainRexx "RexxScriptName", LineNumber
  296.        or
  297.        Value = AdeptChainRexx("RexxScriptName", LineNumber)
  298.  
  299.             Chains REXX files within REXX files.  Runs the rexx script in 
  300.             cached mode.
  301.  
  302.        LineNumber:
  303.             Line number. Passed to REXX routine from Adept as first
  304.             parameter.
  305.        RexxScriptName:
  306.             Name and path of file you want to run.
  307.  
  308.  
  309.  
  310.        AdeptChainRexxNc
  311.        call AdeptChainRexxNc "RexxScriptName", LineNumber
  312.        or
  313.        Value = AdeptChainRexxNc("RexxScriptName", LineNumber)
  314.  
  315.             Chains REXX files within REXX files.  Runs the rexx script in 
  316.             Non-cached mode. Once the script is cached, it is cached (in 
  317.             memory until you shut down your copy of Adept.
  318.  
  319.        LineNumber:
  320.             Line number. Passed to REXX routine from Adept as first
  321.             parameter.
  322.        RexxScriptName:
  323.             Name and path of file you want to run.
  324.  
  325.  
  326.  
  327.  
  328.        AdeptChangeGroup
  329.        call AdeptChangeGroup LineNumber, group_num
  330.        or
  331.        Value = AdeptChangeGroup(LineNumber, group_num)                                                                            10
  332.  
  333.  
  334.  
  335.           The AdeptChangeGroup function will return '0' if the users
  336.           group was not upgraded or not found.  It will return '1'
  337.           if the users group was upgraded.  This works just like
  338.           upgrading a users group in the local user editor.  The user
  339.           will take on the changes specified for the specific group
  340.           that they have joined/are in.
  341.        LineNumber:
  342.             Line number. Passed to REXX routine from Adept as first
  343.             parameter.
  344.        group_num:
  345.             Number of group you want to change the user to.
  346.  
  347.  
  348.  
  349.        AdeptCheckBit
  350.        call AdeptCheckBit Linenumber, BIT NUMBER, Numeric Long
  351.        or
  352.        Value = AdeptCheckBit(Linenumber, BIT NUMBER, Numeric Long)
  353.  
  354.           This can be used to test if a users bit is turned on for any of the
  355.           LONG bitmap'd flags.
  356.  
  357.              Returns '1' if the BIT is set, '0' if it is not.
  358.  
  359.        ** Example **
  360.  
  361.            UserFlag = AdeptGetVar(LineNumber, 42) /* 42 - User Flags */
  362.            IsOn = AdeptCheckBit(LineNumber, 10, UserFlag)
  363.            if IsOn = '1' then
  364.              call AdeptPrint LineNumber, "Flag 10 is on!\r\n"
  365.  
  366.  
  367.  
  368.        AdeptCls
  369.        call AdeptCls LineNumber
  370.        or
  371.        Value = AdeptCls(LineNumber)
  372.  
  373.           Clears local and remote screen.
  374.  
  375.           LineNumber:
  376.             Line number. Passed to REXX routine from Adept as first                                                                            11
  377.  
  378.  
  379.             parameter.
  380.  
  381.        ** Example **
  382.  
  383.            call AdeptCls LineNumber
  384.  
  385.  
  386.  
  387.  
  388.        AdeptComFlush
  389.        call AdeptComFlush LineNumber
  390.        or
  391.        Value = AdeptComFlush(LineNumber)
  392.  
  393.           AdeptComFlush will flush the output stream of the current com port.
  394.           ** BE CAREFUL **
  395.           This is a RAW com function.  This is only to be used by
  396.           professionals or people experienced with programming serial based
  397.           products.
  398.  
  399.        ** Example **
  400.  
  401.            call AdeptComFlush LineNumber
  402.  
  403.  
  404.  
  405.        AdeptComWrite
  406.        call AdeptComWrite LineNumber, string
  407.        or
  408.        Value = AdeptComWrite(LineNumber, string)
  409.  
  410.           AdeptComWrite will place a string into the com ports output stream.
  411.           This is a raw com function.  It will return -1 for carrier drop.
  412.           ** BE CAREFUL **
  413.           This is a RAW com function.  This is only to be used by
  414.           professionals or people experienced with programming serial based
  415.           products.
  416.  
  417.        ** Example **
  418.  
  419.            rc=AdeptComWrite(LineNumber,"Hello!")
  420.            if rc='-1' then signal NoCarrier
  421.              NoCarrier:                                                                            12
  422.  
  423.  
  424.            End
  425.  
  426.           Would be used to Display "Hello" to the output stream, if the
  427.           carrier is dropped, it would signal NoCarrier and the Script
  428.           would be terminated.
  429.  
  430.  
  431.  
  432.        AdeptConvert
  433.        call AdeptConvert LineNumber, String
  434.        or
  435.        Value = AdeptConvert(LineNumber, String)
  436.  
  437.          Converts META variables passed in String.
  438.  
  439.          LineNumber:
  440.             Line number. Passed to REXX routine from Adept as first
  441.             parameter.
  442.          String:
  443.             String which contains META variables which need to be converted.
  444.          Returns:
  445.             Converted string.
  446.  
  447.        ** Example **
  448.  
  449.            dred=AdeptConvert(LineNumber,'{F5')
  450.  
  451.           The variable dred would now equal Dark Red. So where ever you use
  452.           dred it will put it in Dark Red since there are some Functions that
  453.           do not support Meta Codes (NOT just color, ALL Meta Codes)
  454.  
  455.  
  456.  
  457.  
  458.        AdeptDial
  459.        call AdeptDial LineNumber, "STRING TO DIAL"
  460.        or
  461.        Value = AdeptDial(LineNumber, "STRING TO DIAL")
  462.  
  463.          AdeptDial will parse a string to the modem through the dialing
  464.          translation.  I.E. "v~^ATDT555-1212|" will be translated to
  465.          LOWER DTR, PAUSE FOR A SECOND, RAISE DTR, SEND 'ATDT555-1212' then
  466.          a CR (Carriage Return to the modem'.                                                                            13
  467.  
  468.  
  469.  
  470.  
  471.  
  472.        AdeptDoDTR
  473.        call AdeptDoDTR LineNumber, `0' or `1'
  474.        or
  475.        Value = AdeptDoDTR(LineNumber, '0' or '1')
  476.  
  477.        LineNumber:
  478.             Line number. Passed to REXX routine from Adept as first
  479.             parameter.
  480.          Type:
  481.             0 - Drop DTR (Will leave it dropped)
  482.  
  483.             1 - Raise DTR (Will Leave it raised)
  484.  
  485.        ** Example **
  486.  
  487.           call AdeptDoDTR LineNumber,'1'
  488.  
  489.           This will Drop the DTR.
  490.  
  491.  
  492.        AdeptDropGlobalVar
  493.        RetCode = AdeptDropGlobalVar('VarName')
  494.  
  495.  
  496.  
  497.        AdeptFile
  498.        call AdeptFile LineNumber, Type, StartAt, KeyName
  499.        or
  500.        Value = AdeptFile(LineNumber, Type, StartAt, KeyName)
  501.  
  502.          File area manipulation.
  503.  
  504.          LineNumber:
  505.             Line number. Passed to REXX routine from Adept as first
  506.             parameter.
  507.          Type:
  508.            1     Returns name of current file area.
  509.            2     Returns number of current file area.
  510.            3     Find file area (number of area to find in StartAt)
  511.                  Returns file area number                                                                            14
  512.  
  513.  
  514.            4     Find file area (name of area to find in KeyName)
  515.                  Returns name of current file area.
  516.            5     Go to next file area
  517.                  Returns name of current file area.
  518.            6     Go to previous file area
  519.                  Returns name of current file area.
  520.            7     Returns download path of current file area.
  521.            8     Returns upload path of current file area.
  522.          StartAt:
  523.            Number of area to look for. (see type 3)
  524.          Keyname:
  525.            Name of area to look for. (see type 4)
  526.  
  527.        ** Example **
  528.  
  529.            call AdeptFile LineNumber,4,,'AdeptSoft'
  530.            This would find the File area "AdeptSoft" as listed in File_Areas
  531.  
  532.  
  533.        AdeptGetGlobalVar
  534.        RetCode = AdeptGetGlobalVar('VarName')
  535.  
  536.  
  537.        AdeptGetVar and AdeptPutVar
  538.        call AdeptGetVar LineNumber, varnumber
  539.        or
  540.        call AdeptPutVar LineNumber, varnumber, Data
  541.        or
  542.        Value = AdeptGetVar(LineNumber, varnumber)
  543.        or
  544.        Value = AdeptPutVar(LineNumber, varnumber, Data)
  545.  
  546.          This function duplicates some of the functions already in the
  547.          AdeptREXX language.  This returns almost every single variable adept
  548.          uses in the BBS software.  This will give a REXX programmer total
  549.          control over all of the BBS's users and mailers memory variables.
  550.          There will also be some new variables added that will be blank.
  551.          These variables will be usable in real time across nodes by multiple
  552.          REXX programs running at the same time.  The possibilities of such a
  553.          setup are limitless.
  554.  
  555.          The following are the variable numbers:                                                                            15
  556.  
  557.  
  558.           User Info:
  559.             1 - Users Name
  560.             2 - Users Handle
  561.             3 - Users Address
  562.             4 - Users Address1
  563.             5 - Users Address2
  564.             6 - Users City
  565.             7 - Users State
  566.             8 - Users Zipcode
  567.             9 - Users Home Phone
  568.             10 - Users Data Phone
  569.             11 - Users Fax Phone
  570.             12 - Users Business Phone
  571.             13 - Users Interests
  572.             14 - Sysop Comment about User
  573.             15 - Users Bank Time
  574.             16 - Users Computer Type (Number)
  575.             17 - Users User ID
  576.             18 - Users Point ID
  577.             19 - Users BirthYear
  578.             20 - Users BirthMonth
  579.             21 - Users BirthDay
  580.             22 - Users Gender (Represented by 1 letter)
  581.             23 - Users NetMail Credit
  582.             25 - The Group the User belongs to
  583.             27 - Time Used Today
  584.             28 - Time Per Day
  585.             29 - Time Per Call
  586.             30 - Number of calls the user has made
  587.             31 - Upload Number
  588.             32 - Download Number
  589.             33 - Uploads in K
  590.             34 - Downloads in K
  591.             35 - Upload K today
  592.             36 - Download K today
  593.             37 - Upload K per day (Max Allowed)
  594.             38 - Download K per day (Max Allowed)
  595.             39 - Number of posts (Total)
  596.             40 - Security Level #1
  597.             41 - Security Level #2
  598.             42 - Flags represented as a 32-bit long
  599.             43 - Flags2 Represented as a 32-bit long
  600.             44 - User Attributes represented as a 32-bit long                                                                            16
  601.  
  602.  
  603.             45 - User Attributes #2 represented as a 32-bit long
  604.             46 - Users Screen Length
  605.             47 - Users Screen width
  606.             48 - Last Message Area number user was in
  607.             49 - Last File Area Number user was in
  608.             50 - Last Protocol Chosen (Returns the letter for the protocol)
  609.             51 - Last Archiver Chosen Returns Archive Letter
  610.             53 - Percentage of Upload/Download ratio to consider the user a
  611.                  leech
  612.             54 - Maximum Bank time allowed for this user
  613.             55 - Password Represented as a 32-bit long (32-bit CRC)
  614.             56 - Password reversed represented as a 32-bit long (32-bit CRC)
  615.             57 - Max Messages to pack into a mail packet.
  616.             58 - Users Age
  617.             59 - User Bad Password Attempts
  618.             60 - MailStatus (I forget how we use this at the moment)
  619.             61 - Number of lines shown to the remote user since last reset
  620.                  (clear screen or new screen shown, etc).  This is calculated
  621.                  by the display sub-system and should always be correct.
  622.                  This variable takes everything from ANSI and Avatar cursor
  623.                  movement into account, to number of actual lines displayed.
  624.             62 - Did the user pick non-stop display after the last more
  625.                  prompt or non-stop display choice.
  626.  
  627.             BBS Info:
  628.             100 - Number of Calls to the BBS
  629.             101 - Last User ID Assigned by the BBS
  630.             102 - Last Point ID Assigned by the BBS
  631.             103 - Minimum Age Required to Log on
  632.             104 - Maximum Age Allows on the BBS
  633.             105 - Amount of NetMail Credit the user has
  634.             106 - Expire Users after x amount of days
  635.             107 - Expire Users after x amount of minutes
  636.             108 - Default User Time Per Day
  637.             109 - Default User Security Level #1
  638.             110 - Default User Security Level #2
  639.             111 - BBS User Default Flags #1 returned as a 32-bit long
  640.             112 - BBS User Default Flags #2 returned as a 32-bit long
  641.             113 - Default Upload K per day max
  642.             114 - Maximum download k per day
  643.             115 - BBS User Default Attribs returned as a 32-bit long
  644.             116 - BBS User Default Attribs #2 returned as 32-bit long
  645.             117 - The default group the user belongs to.  The user will                                                                            17
  646.  
  647.  
  648.                   inherit the default settings for this group. 0 for none.
  649.             118 - Maximum Users to allow in the user file
  650.             119 - Default Origin Line for EchoMail Areas
  651.             120 - Maximum Password Attempts Allowed
  652.             125 - Default Cost to send a NetMail message
  653.             126 - Line number the BBS is on in the quote file
  654.             127 - Default Maximum Time Per Call
  655.             128 - I don't remember I will have to check this one
  656.             129 - Odds of getting a quote when called
  657.             130 - Mailer Incoming Password Protected Mail Path
  658.             131 - Mailer OkFile for Password Protected Nodes
  659.             132 - Mailer Incoming Public Mail Path
  660.             133 - Mailer OkFile for Public Mail
  661.             134 - Mailer Unlisted Node Mail Path
  662.             135 - Mailer OkFile for Unlisted Nodes
  663.             136 - Number of times a user can page the sysop
  664.             137 - The BBS's Name
  665.             138 - BBS UAttribs 32-bit long
  666.             139 - BBS UAttribs #2 32-bit long
  667.             140 - Sysops Name
  668.             141 - Is The Sysop In (0 or 1)
  669.             142 - Default Max Messages in Packet
  670.             143 - City/State info for BBS & .QWK Packet
  671.             144 - .QWK BBS ID
  672.             145 - BBS .QWK Phone Number
  673.             146 - Default Max Bank Time
  674.  
  675.             Modem/Mailer Info:
  676.             200 - Modem Handle
  677.             201 - Node Number
  678.             202 - Port Name (COM1, \PIPE\ADEPT1, etc)
  679.             203 - Modem Init String
  680.             204 - Default Dialing Prefix
  681.             205 - Default Dialing Suffix
  682.             206 - Optional Dialing Prefix #1
  683.             207 - Optional Dialing Suffix #1
  684.             208 - Optional Dialing Prefix #2
  685.             209 - Optional Dialing Suffix #2
  686.             210 - Optional Dialing Prefix #3
  687.             211 - Optional Dialing Suffix #3
  688.             212 - Optional Dialing Prefix #4
  689.             213 - Optional Dialing Suffix #4
  690.             214 - Optional Dialing Prefix #5                                                                            18
  691.  
  692.  
  693.             215 - Optional Dialing Suffix #5
  694.             216 - Optional Dialing Prefix #6
  695.             217 - Optional Dialing Suffix #6
  696.             218 - Optional Dialing Prefix #7
  697.             219 - Optional Dialing Suffix #7
  698.             220 - Optional Dialing Prefix #8
  699.             221 - Optional Dialing Suffix #8
  700.             222 - Modem Answer String
  701.             223 - Obsolete
  702.             224 - Obsolete
  703.             225 - Mail Only Event Text
  704.             226 - Text if User is too slow
  705.             228 - Baud Rate to Init Modem at
  706.             229 - Minimum Baud rate Allowed on BBS
  707.             230 - Minimum Incoming Baud Rate for Mail
  708.             231 - Minimum Baud Rate to Call Out for Mail
  709.             232 - Maximum Baud Rate for Outbound Mail
  710.             233 - Current Baud Rate of Modem
  711.             234 - Minimum Cost of Mail for This Event (Dialout)
  712.             235 - Maximum Cost of Mail for This Event (Dialout)
  713.             236 - Maximum Mail in K to send in a mail session
  714.             237 - Maximum Time Limit for a mail session
  715.             239 - Maximum Bad Mail Calls before no more are made
  716.             240 - Maximum Times to call a node to send mail
  717.             241 - If Port Locked (0 / 1)
  718.             242 - Allow Human Callers or Users on the BBS? (0/1)
  719.             243 - Allow File Requests (0/1)
  720.             244 - Accept File Request (0/1)
  721.             245 - Dialing Out OK?
  722.             246 - OK To Answer the Phone?
  723.             248 - Force FTS-0001 Mail Sessions (0/1)
  724.             249 - Receive Mail From Unlisted Nodes? (0/1)
  725.             250 - Send Mail to Unlisted Nodes? (0/1)
  726.             251 - Was the last incoming call to the BBS or Mail (1 for BBS, 0
  727.                   for mailer)
  728.             252 - Sealink Overdrive Off (0/1) 1 = off
  729.             253 - Sealink Mail On/Off (1 = on)
  730.             254 - 1k Sealink On/Off (1 = off)
  731.             255 - Allow DietINFA (1 = on (TBBS & XBBS use dietINFA))
  732.             256 - In Chat with Sysop (0/1)
  733.             257 - Debug Transfers (0/1) Extra Log Info
  734.             258 - Allow Hydra Mail Transfers (0/1) (Currently Disabled)
  735.             259 - Allow ZedZip for Mail Transfers (0/1)                                                                            19
  736.  
  737.  
  738.             260 - Allow ZedZap for Mail Transfer (0/1)
  739.             261 - Turn the mailer off? (0/1) 1 = off
  740.             262 - Key to represent Yes (Y) for USA
  741.             263 - Key to represent No (N) for USA
  742.             264 - Key to represent Stop (S) for USA
  743.             264 - Key to represent Pause (P) for USA
  744.             264 - Key to represent Quit (Q) for USA
  745.             268 - Maximum # of resyncs to abort transfers
  746.             269 - Maximum # of transfer errors to abort on
  747.             270 - Last Users on this lines name
  748.             271 - Last Mailer to call this node
  749.             272 - Last Long Entry Written
  750.             276 - Check Carrier Detect (0/1) 1 = on
  751.             277 - Video Display Handle
  752.             278 - Number of ring to wait for answer on this node
  753.  
  754.        ** Examples **
  755.  
  756.            bbsname=AdeptGetVar(LineNumber,137)
  757.            AdeptPrint(line,"\r\nWelcome to"bbsname"! You are welcomed by the
  758.            Sysop")
  759.  
  760.           This would come out like "Welcome to DeathStar/2! You are welcomed
  761.           by The Sysop". (Except DeathStar/2 would be your BBS name :)
  762.  
  763.  
  764.  
  765.  
  766.        AdeptHitReturn
  767.        call AdeptHitReturn LineNumber
  768.        or
  769.        Value = AdeptHitReturn(LineNumber)
  770.  
  771.           AdeptHitReturn will wait for the user to press enter.  This will
  772.           use the Press Enter to continue in the English.Text or other
  773.           language file.
  774.  
  775.        ** Example **
  776.  
  777.           call AdeptHitReturn LineNumber
  778.  
  779.            This would prompt the user to press Enter (return) to continue.                                                                            20
  780.  
  781.  
  782.  
  783.  
  784.  
  785.        AdeptInKey
  786.        call AdeptInKey LineNumber
  787.        or
  788.        Value = AdeptInKey(LineNumber)
  789.  
  790.          AdeptInKey will return the ASCII code for a incoming key sequence.
  791.          AdeptInKey will not wait for a key, it will return 0 if there are no
  792.          keys waiting.  If you use this in a loop, please offset the amount
  793.          of CPU time a loop uses with a AdeptSleep command.
  794.  
  795.        ** Example **
  796.  
  797.           ReturnCode = AdeptInKey(LineNumber)
  798.  
  799.  
  800.  
  801.  
  802.        AdeptInput
  803.        call AdeptInput LineNumber, MinLen, MaxLen, Type, Flags, Prompt, Help,
  804.                HelpFile, Default
  805.        or
  806.        Value = AdeptInput(LineNumber, MinLen, MaxLen, Type, Flags, Prompt,
  807.                Help, HelpFile, Default)
  808.  
  809.          Get a string from the user.
  810.  
  811.          LineNumber:
  812.             Line number. Passed to REXX routine from Adept as first
  813.             parameter.
  814.          MinLen:
  815.            Minimum length of input string.
  816.          MaxLen:
  817.            Maximum length of input string.
  818.          Type:
  819.            Type of input (will define later)
  820.          Flags:
  821.            <undefined>
  822.          Prompt:
  823.            Prompt to display when asking for input.
  824.          Help:                                                                            21
  825.  
  826.  
  827.            Name of subject to look for in HelpFile when user asks for help.
  828.          HelpFile:
  829.            Contains help on subjects pertaining to this input prompt.
  830.          Default:
  831.            Default keystroke.
  832.  
  833.        ** Example **
  834.  
  835.           answer=AdeptInput(LineNumber,1,50,,,'What Is your Name : ',,,)
  836.           call AdeptPrint LineNumber,'\r\n Your name is' answer
  837.  
  838.           This would ask the User for his or her name with a MinLen of 1
  839.           Character and a MaxLen of 50 Characters, with a prompt of "What
  840.           is your Name". When this is printed, it will print to the local
  841.           and remote screen "Your Name is Jean-Ray" (Jean-Ray being the
  842.           name entered).
  843.  
  844.  
  845.        AdeptLibrary
  846.        call AdeptLibraryLineNumber, Type, StartAt, KeyName
  847.        or
  848.        Value = AdeptLibrary(LineNumber, Type, StartAt, KeyName)
  849.  
  850.          Library area manipulation.
  851.  
  852.          LineNumber:
  853.             Line number. Passed to REXX routine from Adept as first
  854.             parameter.
  855.          Type:
  856.            1     Returns name of current library area.
  857.            2     Returns number of current library area.
  858.            3     Find library area (number of area to find in StartAt)
  859.                  Returns library area number
  860.            4     Find library area (name of area to find in KeyName)
  861.                  Returns name of current library area.
  862.            5     Go to next library area
  863.                  Returns name of current library area.
  864.            6     Go to previous library area
  865.                  Returns name of current library area.
  866.            7     Returns path of current library area.
  867.          StartAt:
  868.            Number of area to look for. (see type 3)
  869.          Keyname:                                                                            22
  870.  
  871.  
  872.            Name of area to look for. (see type 4)
  873.  
  874.        ** NOTE: The Adept Library Functions are not yet finished.
  875.  
  876.  
  877.  
  878.        AdeptLocation
  879.        call AdeptLocation LineNumber, "User Location on the BBS"
  880.        or
  881.        Value = AdeptLocation(LineNumber, "User Location on the BBS")
  882.  
  883.           Will display where the User is on the BBS (Sysop defined)
  884.  
  885.        ** Example **
  886.  
  887.           call AdeptLocation LineNumber,"In Door - Barren Realms Elite"
  888.  
  889.          This would display the user on that particular line in a Door of
  890.          Barren Realms Elite.
  891.  
  892.        ** NOTE: Remember, Once the script ends, the location will go back
  893.                 to what it was before the function was executed. This
  894.                 function however is great for Doors and Chat Mode with the
  895.                 Sysop if you Use a Main.Cmd or a .Cmd file for your Door
  896.                 Menu. It can let other users know what Door the other
  897.                 node(s) are in if any.
  898.  
  899.  
  900.        AdeptLog
  901.        call AdeptLog LineNumber, Flags, String1, ..., StringN
  902.        or
  903.        Value = AdeptLog(LineNumber, Flags, String1, ..., StringN)
  904.  
  905.          Log an action.
  906.  
  907.          LineNumber:
  908.             Line number. Passed to REXX routine from Adept as first
  909.             parameter.
  910.          Flags:
  911.             1    Output to log and listbox
  912.             2    Output to log only
  913.             3    Output to listbox only
  914.          String1..N:                                                                            23
  915.  
  916.  
  917.             Strings are added together to form one string which is used to
  918.             spawn the session.
  919.  
  920.        ** Examples **
  921.  
  922.           call AdeptLog LineNumber,2,'Mylog'
  923.  
  924.  
  925.  
  926.        AdeptMenu
  927.        call AdeptMenu LineNumber, Flags, MenuName
  928.        or
  929.        Value = AdeptMenu(LineNumber, Flags, MenuName)
  930.  
  931.          Executes a menu contain in the file MenuName.
  932.  
  933.          LineNumber:
  934.             Line number. Passed to REXX routine from Adept as first
  935.             parameter.
  936.          Flags:
  937.             1    Return after user chooses a command from the menu.
  938.             2    Return after executing all commands contained in menu.
  939.          MenuName:
  940.             File name of the menu to use.
  941.  
  942.        ** Example **
  943.  
  944.           call AdeptMenu LineNumber,2,'Test.Menu'
  945.  
  946.  
  947.  
  948.  
  949.        AdeptMenuType
  950.        call AdeptMenuType LineNumber, menutype, menudata
  951.        or
  952.        Value = AdeptMenuType(LineNumber, menutype, menudata)
  953.  
  954.          This command allows you to execute a menu options 10 - 998.  Just
  955.          pass the standard menudata.
  956.  
  957.        ** Example **
  958.  
  959.           call AdeptMenuTypeLineNumber,42,,,0                                                                            24
  960.  
  961.  
  962.  
  963.           This would display The Users online at the current time.
  964.  
  965.  
  966.  
  967.  
  968.        AdeptMessage
  969.        call AdeptMessage LineNumber, Type, StartAt, KeyName
  970.        or
  971.        Value = AdeptMessage(LineNumber, Type, StartAt, KeyName)
  972.  
  973.          Message area manipulation.
  974.  
  975.          LineNumber:
  976.             Line number. Passed to REXX routine from Adept as first
  977.             parameter.
  978.          Type:
  979.            1     Returns name of current message area.
  980.            2     Returns number of current message area.
  981.            3     Find message area (number of area to find in StartAt)
  982.                  Returns message area number
  983.            4     Find message area (name of area to find in KeyName)
  984.                  Returns name of current message area.
  985.            5     Go to next message area
  986.                  Returns name of current message area.
  987.            6     Go to previous message area
  988.                  Returns name of current message area.
  989.            7     Returns number of messages in current message area.
  990.          StartAt:
  991.            Number of area to look for. (see type 3)
  992.          Keyname:
  993.            Name of area to look for. (see type 4)
  994.  
  995.        ** Example **
  996.  
  997.           call AdeptMessage LineNumber,3,'1',
  998.  
  999.           Would find message area Number 1 as listed in the
  1000.           Adept\System\Message_Areas file.                                                                            25
  1001.  
  1002.  
  1003.        AdeptMore
  1004.        call AdeptMore LineNumber
  1005.        or
  1006.        Value = AdeptMore(LineNumber)
  1007.  
  1008.          AdeptMore will execute a standard more prompt.  This will use the
  1009.          More prompt in the English.Text or other language file.  This will
  1010.          also use the International Y/N/Q/A info.
  1011.  
  1012.  
  1013.  
  1014.        AdeptPause
  1015.        call AdeptPause LineNumber
  1016.        or
  1017.        Value = AdeptPause(LineNumber)
  1018.  
  1019.          AdeptPause will wait for any key.  This does not display any text.
  1020.  
  1021.        ** Example **
  1022.  
  1023.           call AdeptPause LineNumber
  1024.  
  1025.           Will wait for any key to be pressed on current node.
  1026.  
  1027.  
  1028.  
  1029.  
  1030.        AdeptPeekByte
  1031.        call AdeptPeekByteLineNumber, length
  1032.        or
  1033.        Value = AdeptPeekByte(LineNumber, length)
  1034.  
  1035.          Will place the next char in the incoming stream that is waiting.
  1036.          It will NOT remove it from the incoming data steam.
  1037.          Length is the amount of time to wait for the next char to
  1038.          enter the data stream.  (This is a RAW comm function).
  1039.  
  1040.          The software will return TIMEOUT or LOSTCARRIER.
  1041.  
  1042.        ** Example **
  1043.  
  1044.           call AdeptPeekByte LineNumber,6000                                                                            26
  1045.  
  1046.  
  1047.           Will Wait 6 seconds for the next char to enter the data stream.
  1048.  
  1049.  
  1050.  
  1051.  
  1052.        AdeptPrint
  1053.        call AdeptPrint LineNumber, String1, ..., StringN
  1054.        or
  1055.        Value = AdeptPrint(LineNumber, String1, ..., StringN)
  1056.  
  1057.          Prints a string to the local and remote screen. The string may
  1058.          contain Adept META variables.  You may pass more than one or more
  1059.          strings to this function.
  1060.          String1..N:
  1061.             Strings are printed in the order that they were passed.
  1062.  
  1063.        ** Example **
  1064.  
  1065.           call AdeptPrint LineNumber,"Hello! Welcome to The BBS"
  1066.  
  1067.           This Would print "Hello! Welcome to The BBS" to the User online.
  1068.  
  1069.  
  1070.  
  1071.  
  1072.        AdeptPrintL
  1073.        call AdeptPrintL LineNumber, "Text to print locally ONLY"
  1074.        or
  1075.        Value = AdeptPrintL(LineNumber, "Text to print locally ONLY")
  1076.  
  1077.           AdeptPrintL works exactly like AdeptPrint except it prints to the
  1078.           LOCAL screen only.
  1079.  
  1080.  
  1081.  
  1082.        AdeptPutC
  1083.        call AdeptPutC LineNumber, char
  1084.        or
  1085.        Value = AdeptPutC(LineNumber, char)
  1086.  
  1087.           AdeptPutC will put a char into the Com port output stream.  This is
  1088.           a raw com function.  It will return -1 for carrier drop.
  1089.        ** BE CAREFUL**                                                                            27
  1090.  
  1091.  
  1092.           This is a RAW com function.  This is only to be used by
  1093.           professionals or people experienced with programming serial based
  1094.           products.
  1095.  
  1096.        ** Example **
  1097.  
  1098.           call AdeptPutC LineNumber,'A'
  1099.  
  1100.           This would put the letter 'A' in the Com Port's output stream.
  1101.  
  1102.  
  1103.  
  1104.        AdeptPutKey
  1105.        call AdeptPutKey LineNumber, char
  1106.        or
  1107.        Value = AdeptPutKey(LineNumber, char)
  1108.  
  1109.          AdeptPutKey will place a character into keyboard input stream.  Char
  1110.          can be a character i.e. 'A' or a ASCII character code.
  1111.  
  1112.        ** Example **
  1113.  
  1114.           call AdeptPutKey LineNumber,'A'
  1115.  
  1116.           Will put the Character 'A' in the Keyboard's input stream.
  1117.  
  1118.  
  1119.  
  1120.  
  1121.        AdeptRead
  1122.        call AdeptRead LineNumber, Type, Flags, StartAt
  1123.        or
  1124.        Value = AdeptRead(LineNumber, Type, Flags, StartAt)
  1125.  
  1126.          Read messages.
  1127.  
  1128.          LineNumber:
  1129.             Line number. Passed to REXX routine from Adept as first
  1130.             parameter.
  1131.          Type:
  1132.             1    Read messages in current area.
  1133.             2    Globally read messages.
  1134.          Flags:                                                                            28
  1135.  
  1136.  
  1137.             <undefined so far>
  1138.          StartAt:
  1139.             Number of message at which Adept should start reading.
  1140.  
  1141.        ** Examples **
  1142.  
  1143.           call AdeptRead LineNumber,2,,4
  1144.  
  1145.           This would start the user currently online reading the messages
  1146.           globally starting from Message Area #4 (as defined in
  1147.           Adept\System\Message_Areas file).
  1148.  
  1149.  
  1150.  
  1151.  
  1152.        AdeptRecv
  1153.        call AdeptRecv LineNumber, Flags, Path, Area, File1, ..., FileN
  1154.        or
  1155.        Value = AdeptRecv(LineNumber, Flags, Path, Area, File1, ..., FileN)
  1156.  
  1157.          Upload files
  1158.  
  1159.          LineNumber:
  1160.             Line number. Passed to REXX routine from Adept as first
  1161.             parameter.
  1162.          Flags:
  1163.             1    No time verification
  1164.             4    Silence
  1165.             8    Never be silent
  1166.             16   Don't ask for description
  1167.             64   Don't credit upload (does not return files size)
  1168.             128  Accept as private file.
  1169.          Path:
  1170.             Path to put files in.
  1171.          Area:
  1172.             Name of area to put files in.
  1173.          File1..N:
  1174.             Names of files to be received.
  1175.          Returns:
  1176.             String containing number of bytes downloaded, a space and the
  1177.             number of files downloaded.
  1178.  
  1179.          NOTE: This function will change in the future.                                                                            29
  1180.  
  1181.  
  1182.  
  1183.        ** Example **
  1184.  
  1185.           call AdeptRecv line,128,'D:\ADEPT','AdeptSoft','Adept97b.Zip'
  1186.  
  1187.           This will send the File Adept97b.Zip from the AdeptSoft area and
  1188.           the directory of D:\ADEPT
  1189.  
  1190.  
  1191.  
  1192.  
  1193.        AdeptRexxKillThread
  1194.  
  1195.  
  1196.  
  1197.  
  1198.        AdeptRexxStartThread
  1199.        RetCode = AdeptRexxStartThread(FileName, [var1 var2 var3 var4])
  1200.  
  1201.          PARAMETERS
  1202.  
  1203.              FileName - Name of AdeptREXX program to execute as a background
  1204.                         thread.
  1205.  
  1206.              Var1 - Variable to pass to the rexx program, you can pass as
  1207.                     many variables you want.  They are not shared once they
  1208.                     are passed. See - AdeptSetGlobalVar and
  1209.                     AdeptGetGlobalVar
  1210.  
  1211.          RETURNS
  1212.  
  1213.              REXX Error Codes
  1214.  
  1215.          EXAMPLE
  1216.  
  1217.              rc = AdeptRexxStart('Thread.Cmd', line)
  1218.  
  1219.          DESCRIPTION
  1220.  
  1221.              This will cause the program Thread.Cmd to be run in the
  1222.              background with the rexx programming calling it as the parent.
  1223.              When the parent ends, all children and grandchildren are killed
  1224.              with it.                                                                            30
  1225.  
  1226.  
  1227.  
  1228.          RELATED FUNCTIONS
  1229.  
  1230.              AdeptKillRexxThread, AdeptSetGlobalVar, AdeptGetGlobalVar,
  1231.              AdeptDropGlobalVar
  1232.  
  1233.  
  1234.  
  1235.  
  1236.  
  1237.        AdeptSend
  1238.        call AdeptSend LineNumber, Flags, Path, File1, ..., FileN
  1239.        call AdeptSent LineNumber,,,''@file''
  1240.        or
  1241.        Value = AdeptSend(LineNumber, Flags, Path, File1, ..., FileN)
  1242.        Value = AdeptSent(LineNumber,,,''@file'')
  1243.  
  1244.          Download Files.
  1245.  
  1246.          LineNumber:
  1247.             Line number. Passed to REXX routine from Adept as first
  1248.             parameter.
  1249.          Flags:
  1250.             1    No time verification
  1251.             2    No leech checking
  1252.             4    Silence
  1253.             8    Never be silent
  1254.             16   Don't check all download paths
  1255.             64   Don't return files length (free file/bytes)
  1256.          Path:
  1257.             Path to files.  If blank, use current file area path.
  1258.          File1..N:
  1259.             Names of files to be sent.
  1260.             NOTE: Currently the files are sent one at a time.
  1261.          @File:
  1262.             Text file with the filenames and paths (one per line) of
  1263.             the files to send.
  1264.          Returns:
  1265.             String containing number of bytes downloaded, a space and the
  1266.             number of files downloaded.
  1267.  
  1268.  
  1269.        ** Example **                                                                            31
  1270.  
  1271.  
  1272.  
  1273.           call AdeptSend LineNumber,,,'@c:\list')
  1274.  
  1275.           Will send the File that is in the file called list.
  1276.  
  1277.  
  1278.  
  1279.        AdeptSetBit
  1280.        call AdeptSetBit LineNumber, BIT NUMBER, Numeric Long
  1281.        or
  1282.        Value = AdeptSetBit(LineNumber, BIT NUMBER, Numeric Long)
  1283.  
  1284.           Will set BIT Number 1 - 32 to ON.
  1285.           The changes are not saved until you put the changes back into
  1286.           active memory with the AdeptPutVar option.
  1287.  
  1288.        ** Example **
  1289.  
  1290.           SetBit= AdeptGetVar(LineNumber,42)
  1291.           call AdeptSetBit LineNumber,30,SetBit
  1292.  
  1293.  
  1294.  
  1295.        AdeptSetGlobalVar
  1296.        RetCode = AdeptSetGlobalVar('VarName', Value)
  1297.  
  1298.  
  1299.  
  1300.  
  1301.  
  1302.        AdeptSetTimer
  1303.        call AdeptSetTimer LineNumber, Timer
  1304.        or
  1305.        Value = AdeptSetTimer(LineNumber, Timer)
  1306.  
  1307.           LineNumber:
  1308.              Passed to REXX routine from Adept as First Parameter.
  1309.           Timer: Time In Milliseconds
  1310.  
  1311.        ** Example **
  1312.  
  1313.           call AdeptSetTimer LineNumber,10000  /* 10 seconds */                                                                            32
  1314.  
  1315.  
  1316.  
  1317.  
  1318.        AdeptShow
  1319.        call AdeptShow LineNumber, Type, Flags, StartAt, KeyName
  1320.        or
  1321.        Value = AdeptShow(LineNumber, Type, Flags, StartAt, KeyName)
  1322.  
  1323.          Display text files.
  1324.  
  1325.          LineNumber:
  1326.             Line number. Passed to REXX routine from Adept as first
  1327.             parameter.
  1328.          Type:
  1329.            1     Show a text file (StartAt=filename, KeyName=keys to abort
  1330.                  on)
  1331.            2     Page-read text file (Keyname=filename)
  1332.            3     Show new text files (Keyname=directory to look in)
  1333.            4     Show any text file (Keyname=directory to look in)
  1334.          Flags:
  1335.            <undefined> (for now)
  1336.          StartAt:
  1337.            (see type 1)
  1338.          KeyName:
  1339.            Keys on which to abort showing of the text file. (see type 1)
  1340.            -or-
  1341.            Name of file or directory to look for. (see types 2-4)
  1342.  
  1343.        ** Examples **
  1344.  
  1345.           call AdeptShow LineNumber,1,,'C:\Adept\Text\Bullet.Ans,Q
  1346.  
  1347.           This would display the Bullet.Ans file in the Adept\Text directory
  1348.           and if the User presses the letter 'Q' it will abort viewing of the
  1349.           file.
  1350.  
  1351.  
  1352.  
  1353.  
  1354.        AdeptSleep
  1355.        call AdeptSleep LineNumber, time_to_sleep_in_milliseconds
  1356.        or
  1357.        Value = AdeptSleep(LineNumber, time_to_sleep_in_milliseconds)                                                                            33
  1358.  
  1359.  
  1360.          AdeptSleep will cause the current node to sleep for x amount of
  1361.          milli-seconds.  This is very helpful in making your REXX scripts CPU
  1362.          friendly. When you use this command it will release the current time
  1363.          slice to the next node or program waiting in line.  A decent sleep
  1364.          amount is AdeptSleep(65), 65 milliseconds, 1000 milliseconds = 1
  1365.          second.
  1366.          The smallest timeslice OS/2 can sleep is 32ms.
  1367.  
  1368.        ** Examples **
  1369.  
  1370.           call AdeptSleep LineNumber,1000    /* 1 Second   */
  1371.           call AdeptSleep LineNumber,10000   /* 10 Seconds */
  1372.           call AdeptSleep LineNumber,60000   /* 1 Minute   */
  1373.           call AdeptSleep LineNumber,600000  /* 10 Minutes */
  1374.  
  1375.  
  1376.  
  1377.  
  1378.        AdeptTimedInKey
  1379.        call AdeptTimedInKey LineNumber,timeout
  1380.        or
  1381.        Value = AdeptTimedInKey(LineNumber,timeout)
  1382.  
  1383.          Returns the value for the key imputed, watched the port for a
  1384.          period of time in milliseconds.
  1385.  
  1386.        ** Example **
  1387.  
  1388.           KeyIn=AdeptTimedInKey(LineNumber,5000)    /* 5 seconds */
  1389.  
  1390.        ** NOTE: KeyIn contains the key pressed or -1 or 0 for timeout or -2
  1391.                 for carrier loss.
  1392.  
  1393.  
  1394.  
  1395.  
  1396.        AdeptTimeLeft
  1397.        call AdeptTimeLeft LineNumber[, SecsLeftInSession]
  1398.        or
  1399.        Value = AdeptTimeLeft(LineNumber[, SecsLeftInSession])
  1400.  
  1401.          Optionally sets time left in current session. Always returns time
  1402.          left in current session.                                                                            34
  1403.  
  1404.  
  1405.  
  1406.          LineNumber:
  1407.             Line number. Passed to REXX routine from Adept as first
  1408.             parameter.
  1409.          SecsLeftInSession:
  1410.             Optional.  Set seconds left in current session.
  1411.          Returns:
  1412.             Time left in session in seconds.
  1413.  
  1414.        ** Example **
  1415.  
  1416.           call AdeptTimeLeft LineNumber, 60000
  1417.  
  1418.           This will give the user online 1 minute left in his/her session.
  1419.  
  1420.  
  1421.  
  1422.  
  1423.        AdeptTimerUp
  1424.        call AdeptTimerUp LineNumber, Timer
  1425.        or
  1426.        Value = AdeptTimerUp(LineNumber, Timer)
  1427.  
  1428.           AdeptTimerUp will return 0 if timer is Up or 1 if it is Not
  1429.  
  1430.        ** Example with the TWO PREVIOUS rexx Functions **
  1431.  
  1432.            Timer=AdeptSetTimer(LineNumber,10000)  /* 10 Seconds */
  1433.            MyRet=AdeptTimerUp(LineNumber,timer)
  1434.  
  1435.           MyRet = 0 if timer is up or 1 if it is not.
  1436.  
  1437.  
  1438.  
  1439.  
  1440.        AdeptUnsetBit
  1441.        call AdeptUnsetBit LineNumber, BIT NUMBER, Numeric Long
  1442.        or
  1443.        Value = AdeptUnsetBit(LineNumber, BIT NUMBER, Numeric Long)
  1444.  
  1445.          Will set BIT Number 1 - 32 to OFF.
  1446.          The changes are not saved until you put the changes back into active
  1447.          memory with the AdeptPutVar option.                                                                            35
  1448.  
  1449.  
  1450.  
  1451.        ** Example **
  1452.  
  1453.           call AdeptUnsetBit LineNumber, 30, SetBit
  1454.  
  1455.           Will turn bit number 30 OFF.
  1456.  
  1457.        ***NOTE : The changes are not saved until you put the changes back
  1458.                  into active memory with the AdeptPutVar option.
  1459.  
  1460.  
  1461.  
  1462.  
  1463.        AdeptWaitConnect
  1464.        call AdeptWaitConnect LineNumber, Time
  1465.        or
  1466.        Value = AdeptWaitConnect(LineNumber, Time)
  1467.  
  1468.           AdeptWaitConnect will wait for a modem connect or error code.  It
  1469.           will return 0 if it time outs if it doesn't timeout it will
  1470.           then return the return code from the modem i.e. 'CONNECT 28800'
  1471.           'ERROR', 'OK', 'NO CARRIER'.
  1472.  
  1473.           The time is in the format of milliseconds.
  1474.  
  1475.  
  1476.  
  1477.  
  1478.        AdeptWaitKey
  1479.        call AdeptWaitKey LineNumber
  1480.        or
  1481.        Value = AdeptWaitKey(LineNumber)
  1482.  
  1483.          AdeptWaitKey will return the ASCII code for a incoming key sequence.
  1484.          Unlike AdeptInKey, AdeptWaitKey will actually wait for a key
  1485.          sequence. If the user times out, it will log the user off.
  1486.  
  1487.        ** Example **
  1488.  
  1489.           ReturnCode = AdeptInKey(LineNumber)                                                                            36
  1490.  
  1491.  
  1492.  
  1493.  
  1494.        AdeptWrite
  1495.        call AdeptWrite LineNumber, Type, Flags, Filename
  1496.        or
  1497.        Value = AdeptWrite(LineNumber, Type, Flags, Filename)
  1498.  
  1499.          Write a message.
  1500.  
  1501.          LineNumber:
  1502.             Line number. Passed to REXX routine from Adept as first
  1503.             parameter.
  1504.          Type:
  1505.             1    Write a message  (Filename is unused)
  1506.             2    edit file using editor (Flags are unused)
  1507.          Flags:
  1508.             1    Force message to force-to-name of current message area.
  1509.             2    Force private
  1510.             4    Force public
  1511.             8    Use MSGTMP.LineNumber file
  1512.          Filename:
  1513.             Name of text file to edit.
  1514.  
  1515.        ** Example **
  1516.  
  1517.           call AdeptWrite LineNumber, 1, 4,
  1518.  
  1519.           This would write a public message in the current area.
  1520.  
  1521.  
  1522.  
  1523.        AfSysAddIndexEntries
  1524.        RetCode = AfSysAddIndexEntries(fSysHandle)
  1525.  
  1526.        AfSysAddIndexEntries adds entries in the indexes for a file.
  1527.  
  1528.        PARAMETERS
  1529.          fSysHandle- input
  1530.              Handle to the currently open file system.
  1531.  
  1532.        RETURNS
  1533.          Return Code.                                                                            37
  1534.  
  1535.  
  1536.          AfSysAddIndexEntries may return the following values:
  1537.  
  1538.          0           No errors.
  1539.          92          FSYS_ERROR_SEM_TIMEOUT
  1540.          200         FSYS_ERROR_ADDING_DATED
  1541.          201         FSYS_ERROR_ADDING_ANAME
  1542.          202         FSYS_ERROR_ADDING_NAME
  1543.  
  1544.        REMARKS
  1545.          Index data should be set using the AfSysSetIndexXXXX series of
  1546.          functions before adding a file to the indexes.
  1547.  
  1548.        EXAMPLE CODE
  1549.          This example deletes the old index entries for a file, set the new
  1550.          index data, then adds in the new index entries.
  1551.  
  1552.              FSysDeleteIndexEntries(hFSys)
  1553.  
  1554.              /* set new index data */
  1555.              AfSysGetFileName(fSysHandle, 'Buffer')
  1556.  
  1557.              AfSysSetIndexFilename(fSysHandle, Buffer)
  1558.  
  1559.              AfSysGetFileDate(fSysHandle, 'Date')
  1560.  
  1561.              AfSysSetIndexEntryDate(fSysHandle, Date.1, Date.2, Date.3)
  1562.  
  1563.              AreaNum = FSysGetFileArea(fSysHandle)
  1564.  
  1565.              AfSysSetIndexAreaNumber(fSysHandle, AreaNum)
  1566.  
  1567.              /* add in new index entries */
  1568.              FSysAddIndexEntries(fSysHandle);
  1569.  
  1570.  
  1571.        AfSysClose
  1572.        RetCode = AfSysClose(fSysHandle)
  1573.  
  1574.          AfSysClose close the file system.
  1575.  
  1576.          PARAMETERS
  1577.  
  1578.            fSysHandle - input                                                                            38
  1579.  
  1580.  
  1581.                Handle to the currently open file system.
  1582.  
  1583.          RETURNS
  1584.            Return Code.
  1585.  
  1586.            AfSysClose may return the following values:
  1587.  
  1588.            0           No errors.
  1589.  
  1590.          EXAMPLE CODE
  1591.            This example calls AfSysOpen and creates new file system files,
  1592.            then closes the file system.
  1593.  
  1594.                RetCode = AfSysOpen('.\Files', 'fSysHandle', 'FALSE')
  1595.                  .
  1596.                  .
  1597.                  // use the file system.
  1598.                  .
  1599.                  .
  1600.                RetCode = fSysClose(fSysHandle)
  1601.  
  1602.  
  1603.  
  1604.        AfSysDeleteIndexEntries
  1605.        RetCode = AfSysDeleteIndexEntries(fSysHandle)
  1606.  
  1607.        AfSysDeleteIndexEntries deletes a file from all of the indexes.
  1608.  
  1609.        PARAMETERS
  1610.          fSysHandle - input Handle to the currently open file system.
  1611.  
  1612.        RETURNS
  1613.          Return Code.
  1614.  
  1615.          AfSysDeleteIndexEntries may return the following values:
  1616.  
  1617.          0           No errors.
  1618.          92          FSYS_ERROR_SEM_TIMEOUT
  1619.          190         FSYS_ERROR_DELETING_DATED
  1620.          191         FSYS_ERROR_DELETING_ANAME
  1621.          192         FSYS_ERROR_DELETING_NAME
  1622.  
  1623.        REMARKS                                                                            39
  1624.  
  1625.  
  1626.          AfSysDeleteIndexEntries deletes all refrences to a certain file in
  1627.          the indexes. It does NOT remove that files record from the data
  1628.          file.
  1629.  
  1630.          To set which file you wish to delete, you must either search for,
  1631.          and find the file using the searching functions or you must use the
  1632.          AfSysSetIndexXXXXX series of functions to set the correct filename,
  1633.          date, area name and file record offset.  Obviously it is best to
  1634.          search for the file, find it and confirm it is the file you wish to
  1635.          delete before you delete it.
  1636.  
  1637.        EXAMPLE CODE
  1638.          Assuming you have already set the file index information this
  1639.          example calls AfSysDeleteIndexEntries to delete the file from the
  1640.          indexes.
  1641.  
  1642.              RetCode = AfSysDeleteIndexEntries(fSysHandle)
  1643.  
  1644.  
  1645.  
  1646.        AfSysOpen
  1647.        RetCode = AfSysOpen(Directory, fSysHandle, Create)
  1648.  
  1649.        FSysOpen should be called by each program in the process which wants
  1650.        to use the file system.
  1651.  
  1652.        PARAMETERS
  1653.  
  1654.          Directory -
  1655.              This is the directory that the files system is located in.
  1656.              Normally a program which uses the Adept file system is started
  1657.              in the '\Adept' directory and the files system would then be in
  1658.              '.\Files' or more simply, 'Files'.   The directory name should
  1659.              NOT end with a backslash or forward slash.
  1660.  
  1661.          FSysHandle - output
  1662.              This contains the handle to the file system.
  1663.  
  1664.          Create - input
  1665.              Tells the file system whether to open the current file system
  1666.              files or to create new ones.
  1667.  
  1668.              FALSE - Open current files.                                                                            40
  1669.  
  1670.  
  1671.              TRUE  - Create/Open new files.
  1672.  
  1673.        RETURNS
  1674.  
  1675.          Return Code.
  1676.  
  1677.            AFSysOpen may return the following values:
  1678.  
  1679.            0           No errors.
  1680.            90          FSYS_ERROR_ALLOC_MEM
  1681.            91          FSYS_ERROR_INIT_BIDX
  1682.            100         FSYS_ERROR_OPEN_DATA
  1683.            101         FSYS_ERROR_OPEN_DESC
  1684.            102         FSYS_ERROR_OPEN_PATH
  1685.            103         FSYS_ERROR_OPEN_NIDX
  1686.            104         FSYS_ERROR_OPEN_DIDX
  1687.            105         FSYS_ERROR_OPEN_AIDX
  1688.            180         FSYS_ERROR_CREATING_KEY
  1689.  
  1690.          REMARKS
  1691.            A successful AfSysOpen request returns a handle to the file
  1692.            system. All other calls to the file system functions require this
  1693.            handle.
  1694.  
  1695.            Note: When you choose to create a new file system, the indexes are
  1696.            destroyed if they exist. All other files are opened and NOT
  1697.            destroyed.
  1698.            If you wish to create all files from scratch, make sure there are
  1699.            no files in the directory.
  1700.  
  1701.            You could call AfSysOpen twice with a different directory to open
  1702.            two different files system to copy entries from one file system
  1703.            to another.
  1704.  
  1705.          EXAMPLE CODE
  1706.  
  1707.          This example calls AfSysOpen and uses the current file system
  1708.          files.
  1709.  
  1710.                RetCode = FSysOpen('.\Files', 'FSysHandle', 'FALSE')                                                                            41
  1711.  
  1712.  
  1713.        AfSysSetIndexAreaNumber
  1714.  
  1715.  
  1716.  
  1717.        AfSysSetIndexEntryDate
  1718.  
  1719.  
  1720.  
  1721.        AfSysSetIndexFileName
  1722.  
  1723.  
  1724.  
  1725.        AfSysSetIndexRecordOffset
  1726.        AfSysSetFileName
  1727.        AfSysGetFileName
  1728.        AfSysSetUploader
  1729.        AfSysGetUploader
  1730.        AfSysSetFileSize
  1731.        AfSysGetFileSize
  1732.        AfSysSetFileArea
  1733.        AfSysGetFileArea
  1734.        AfSysSetFileDate
  1735.        AfSysGetFileDate
  1736.        AfSysGetFileDescription
  1737.        AfSysSetFileDescription
  1738.        AfSysSetListable
  1739.        AfSysGetListable
  1740.        AfSysGetFreeFile
  1741.        AfSysGetFreeTime
  1742.        AfSysGetFreeBytes
  1743.        AfSysgetSecLevel
  1744.        AfSysGetCopyFile
  1745.        AfSysGetAge
  1746.        AfSysGetDlAble
  1747.        AfSysGetPathName
  1748.        AfSysGetTimesDl
  1749.        AfSysSetPathIndex
  1750.        AfSysSetAge
  1751.        AfSysSetDlAble
  1752.        AfSysSetSecLevel
  1753.        AfSysSetReadDescFlag
  1754.        AfSysSetCopyFile
  1755.        AfSysSetFileRecord                                                                            42
  1756.  
  1757.  
  1758.        AfSysSetDescOffset
  1759.        AfSysReadFilePath
  1760.        AfSysWriteFilePath
  1761.        AfSysFindFirstName
  1762.        AfSysFindNextName
  1763.        AfSysFindExact
  1764.        AfSysListFirst
  1765.        AfSysListNext
  1766.        AfSysZeroFileRecord
  1767.        AfSysFirstName
  1768.        AfSysAddIndexEntries
  1769.        AfSysResetFilePtr
  1770.        AfSysResetDescFilePtr
  1771.        AfSysReadDescriptionLine
  1772.        AfSysRawReadFileRecord
  1773.  
  1774.        AdeptComPutC
  1775.        AdeptComWrite
  1776.        AdeptComPeekByte
  1777.        AdeptComGetByte
  1778.        AdeptComDoDTR
  1779.        AdeptComFlush
  1780.        AdeptComGetString
  1781.        AdeptComGetBlock
  1782.        AdeptComWaitConnect
  1783.        AdeptComDial
  1784.        AdeptRawOpenSocket
  1785.        AdeptRawComOpen
  1786.        AdeptRawComClose
  1787.        AdeptRawComGetBlock
  1788.        AdeptRawComGetString
  1789.        AdeptRawComWrite
  1790.        AdeptRawSetBPS
  1791.        AdeptRawComLink
  1792.  
  1793.        ReturnComPort
  1794.  
  1795.        AdeptTimeLeft
  1796.        AdeptCurPos
  1797.  
  1798.        AdeptSayGen
  1799.        AdeptPlayMM
  1800.        Adept16BitCRC                                                                            43
  1801.  
  1802.  
  1803.        Adept32BitCRC
  1804.        AdeptCheckForMail
  1805.        AdeptChangeGroup
  1806.        AdeptSetBit
  1807.        AdeptUnsetBit
  1808.        AdeptCheckBit
  1809.        AdeptGetVar
  1810.        AdeptPutVar
  1811.        AdeptPrint
  1812.        Print
  1813.        AdeptPrintL
  1814.        Printf
  1815.        AdeptCall
  1816.        AdeptInput
  1817.        AdeptSend
  1818.        AdeptRecv
  1819.        AdeptMenu
  1820.        AdeptConvert
  1821.        AdeptCls
  1822.        AdeptWrite
  1823.        AdeptRead
  1824.        AdeptFile
  1825.        AdeptMessage
  1826.        AdeptShow
  1827.        AdeptSleep
  1828.        AdeptInKey
  1829.        AdeptWaitKey
  1830.        AdeptPutKey
  1831.        AdeptCheckCard
  1832.        AdeptSetTimer
  1833.        AdeptTimedInkey
  1834.        AdeptTimerUp
  1835.        AdeptLocation
  1836.        AdeptHitReturn
  1837.        AdeptMore
  1838.        AdeptPause
  1839.  
  1840.        AChatSendMsg     - Multi-node chat
  1841.        AChatGetMsg      - Multi-node chat
  1842.        AChatDeleteAll   - Multi-node chat
  1843.        AChatUnavailable - Multi-node chat
  1844.  
  1845.        AdeptCheckCard   - Validate credit card                                                                            44
  1846.  
  1847.  
  1848.        -- Userbase minipulation functions --
  1849.  
  1850.        AdeptGetUser       - Get a user and pull their record into a temp var
  1851.        AdeptNextUser      - Get next user in the file and pull into a temp
  1852.        var
  1853.        AdeptPrevUser      - Get prev user in the file and pull into a temp
  1854.        var
  1855.        AdeptGetUserVar    - Get functions for temp user in memory
  1856.        AdeptPutUserVar    - Put functions for temp user in memory
  1857.        AdeptSaveUser      - Saved the temp memory vars to users record                                                                            45
  1858.  
  1859.  
  1860.        CTRL AND OTHER KEYS AND THEIR RETURN CODES:
  1861.  
  1862.  
  1863.        CTRL_A = 1        CTRL_B = 2        CTRL_C = 3        CTRL_D = 4
  1864.        CTRL_E = 5        CTRL_F = 6        CTRL_G = 7        CTRL_H = 8
  1865.        CTRL_I = 9        CTRL_J = 10       CTRL_K = 11       CTRL_L = 12
  1866.        CTRL_N = 14       CTRL_O = 15       CTRL_P = 16       CTRL_Q = 17
  1867.        CTRL_R = 18       CTRL_S = 19       CTRL_T = 20       CTRL_U = 21
  1868.        CTRL_V = 22       CTRL_W = 23       CTRL_X = 24       CTRL_Y = 25
  1869.        CTRL_Z = 26
  1870.  
  1871.        HOME   = 71+1024  UP     = 72+1024  PGUP   = 73+1024  BS     = 75+1024
  1872.        FWD    = 77+1024  END    = 79+1024  DN     = 80+1024  PGDN   = 81+1024
  1873.        INS    = 82+1024  DEL    = 83+1024  LEFT   = 75+1024  RIGHT  = 77+1024
  1874.