home *** CD-ROM | disk | FTP | other *** search
/ The World of Computer Software / World_Of_Computer_Software-02-386-Vol-2of3.iso / c / commo541.zip / MACRO.DOC < prev    next >
Text File  |  1993-02-13  |  168KB  |  5,080 lines

  1.  
  2.  
  3.  
  4.  
  5.  
  6.  
  7.  
  8.  
  9.                                 ____________
  10.  
  11.                                 {COMMO} (tm)
  12.                                 ____________
  13.  
  14.  
  15.                    "A New Standard in Telecommunications"
  16.  
  17.  
  18.  
  19.  
  20.  
  21.  
  22.  
  23.  
  24.  
  25.                                      by
  26.  
  27.                               Fred P. Brucker
  28.  
  29.                             Post Office Box 9103
  30.                             Santa Rosa, CA 95405
  31.  
  32.  
  33.  
  34.  
  35.  
  36.  
  37.                           Macro Programming Guide
  38.  
  39.  
  40.  
  41.  
  42.                                 Release 5.41
  43.  
  44.                              February 13, 1993
  45.  
  46.  
  47.  
  48.  
  49.  
  50.  
  51.  
  52.  
  53.  
  54.  
  55.  
  56.  
  57.  
  58.         (C)Copyright 1989-1993  Fred P. Brucker  All Rights Reserved
  59.  
  60.  
  61.  
  62.  
  63.  
  64.      The {COMMO} program and associated on-disk documentation are the
  65.      property of the author and may not be sold without permission. 
  66.      The Shareware version may be distributed, unaltered and as a
  67.      unit, via Electronic Bulletin Board Systems.
  68.  
  69.      SHAREWARE DISTRIBUTORS and clubs, please see the file VENDOR.DOC
  70.      for distribution guidelines.
  71.  
  72.  
  73.      THE AUTHOR DOES NOT GUARANTEE THIS PROGRAM TO BE FREE FROM
  74.      DEFECTS AND MAY NOT BE HELD RESPONSIBLE FOR LOSS CAUSED BY SUCH. 
  75.      YOUR USE OF THIS PROGRAM CONSTITUTES YOUR ACCEPTANCE OF THESE
  76.      TERMS.
  77.  
  78.  
  79.  
  80.  
  81.      DESQview is a trademark of Quarterdeck Office Systems
  82.      OmniView is a trademark of Sunny Hill Software
  83.      DoubleDOS is a trademark of SoftLogic Solutions, Inc.
  84.      HS/Link is a product of Samuel H. Smith
  85.      DSZ and GSZ are products of Omen Technology Inc.
  86.      MPt is a product of Matthew Thomas
  87.      LIST is a product of Vernon D. Buerg
  88.      The IBM PC is a product of IBM Corp.
  89.      MS-DOS is a trademark of MicroSoft Corp.
  90.  
  91.  
  92.  
  93.  
  94.         (C)Copyright 1989-1993  Fred P. Brucker  All Rights Reserved
  95.  
  96.  
  97.  
  98.                      ================================ 
  99.                      {COMMO} Registration Information 
  100.                      ================================ 
  101.  
  102.   {COMMO} is a "SHAREWARE" product.  You are entitled to evaluate it for 
  103.   30 days.  If it suits your needs and you would like to continue using 
  104.   it, then you must pay the licensing fee.  Please use the REGISTRATION 
  105.   FORM on the next page. 
  106.  
  107.   When you REGISTER you will be licensed to use all future SHAREWARE 
  108.   releases of {COMMO}.  You will never have to pay an "update" charge. 
  109.   You will also receive instructions for removing the Shareware Notice 
  110.   at program startup. 
  111.  
  112.   My (voice) TELEPHONE NUMBER for inquiries and support for registered 
  113.   users is (707) 573-1065.  Please restrict calls to business hours 
  114.   (Mon-Fri, 9am-5pm, Pacific time). 
  115.  
  116.   Registered users will also receive priority support on Bulletin Boards, 
  117.   CompuServe and GEnie (see READ.ME). 
  118.  
  119.   Call or write for pricing information on MULTI-USER (site) and 
  120.   DISTRIBUTION licenses.  Discounts are given on quantities of 10 or more. 
  121.   See the file LICENSE.DOC for details. 
  122.  
  123.   All prices shown are US DOLLARS.  Please remit US FUNDS on US BANK only. 
  124.   NET 30 TERMS will be accepted on purchase orders totalling $100.00 or 
  125.   more. 
  126.  
  127.   PAYMENT OPTIONS: 
  128.  
  129.   1) Payment by CHECK or MONEY ORDER:  make payable to FRED P. BRUCKER. 
  130.      Mail the Registration Form and payment to the address below. 
  131.  
  132.   2) Payment by CREDIT CARD:  fill in the credit card information at the 
  133.      bottom of the Registration Form.  The following cards are accepted: 
  134.  
  135.          VISA, MASTERCARD, CARTE BLANCHE, DINERS CLUB, JCB. 
  136.  
  137.      You can mail the Registration Form to the address below or: 
  138.  
  139.      Order by phone: (707) 573-1065, Mon-Fri, 9am-5pm, Pacific time. 
  140.      Have your credit card ready when you call. 
  141.  
  142.      Order by E-mail on CompuServe (71021,356) or GEnie (F.BRUCKER1). 
  143.      Upload the completed Registration Form as a message. 
  144.  
  145.      The company name on the charge will be "New Standard Software." 
  146.  
  147.  
  148.                 SEND TO:   Fred P. Brucker 
  149.                            Post Office Box 9103 
  150.                            Santa Rosa, CA 95405
  151.  
  152.  
  153.  
  154.                {COMMO} 5.41 SINGLE USER REGISTRATION FORM 
  155.  
  156.   Name     _______________________________________________________________ 
  157.  
  158.   Company name (if company address)   ____________________________________ 
  159.  
  160.   Address  _______________________________________________________________ 
  161.  
  162.            _______________________________________________________________ 
  163.  
  164.            _______________________________________________________________ 
  165.  
  166.  
  167.   {COMMO} single user license, SPECIAL PACKAGE .... $50.00**  $ __________ 
  168.     Includes: (1) Printed, bound, indexed manual. 
  169.               (2) Latest release on diskette plus utilities 
  170.                   (COMMOPNS, MOSTHOST, CMC, etc., see READ.ME). 
  171.                   Diskette format: 5.25" ____ 3.5" ____ 
  172.  
  173.   {COMMO} single user license, with DISKETTE ...... $40.00    $ __________ 
  174.                   Diskette format: 5.25" ____ 3.5" ____ 
  175.  
  176.   {COMMO} single user LICENSE alone ............... $35.00    $ __________ 
  177.  
  178.   BBS sysops, students, seniors, low-income ....... $25.00    $ __________ 
  179.     (license only; provide details on back of form) 
  180.  
  181.                                                   Subtotal    $ __________ 
  182.  
  183.                   California residents add sales tax, 7.5%    $ __________ 
  184.                     (No tax when ordering license alone) 
  185.  
  186.   ** SPECIAL PACKAGE ORDER, ADD SHIPPING: 
  187.                          USA/Canada/Mexico ......... $3.00 
  188.                          All other countries ...... $10.00    $ __________ 
  189.  
  190.                                                      Total    $ __________ 
  191.  
  192.   Payment method:  Check__  Money order__  Visa__  MasterCard__ 
  193.                    Carte Blanche__  Diners Club__  JCB__   PO__ 
  194.  
  195.      CREDIT CARD INFORMATION: 
  196.  
  197.      Card No. ________  ________  ________  ________  Expires ____/____ 
  198.  
  199.      Cardholder signature _____________________________________________ 
  200.  
  201.      Cardholder name __________________________________________________ 
  202.  
  203.      Daytime telephone  (_____) _____ _______ 
  204.  
  205.  
  206.  
  207.  
  208.   Answers to the following questions will help me serve you better in the 
  209.   future: 
  210.  
  211.   How did you obtain {COMMO}?  (If BBS, please give name and phone number) 
  212.  
  213.   ________________________________________________________________________ 
  214.  
  215.   What kind of systems do you call with {COMMO}? 
  216.  
  217.   ________________________________________________________________________ 
  218.  
  219.   ________________________________________________________________________ 
  220.  
  221.   What type of computer and modem do you use? 
  222.  
  223.   ________________________________________________________________________ 
  224.  
  225.   ________________________________________________________________________ 
  226.  
  227.  
  228.   Comments / Questions ___________________________________________________ 
  229.  
  230.   ________________________________________________________________________ 
  231.  
  232.   ________________________________________________________________________ 
  233.  
  234.   ________________________________________________________________________ 
  235.  
  236.   ________________________________________________________________________ 
  237.  
  238.   
  239.   Thank you, and I hope you enjoy {COMMO}.
  240.  
  241.  
  242.  
  243.                    {COMMO} (tm)  Macro Programming Guide             6
  244.  
  245.  
  246.      ========
  247.      Contents
  248.      ========
  249.  
  250.  
  251.      Programming {COMMO} Macros  . . . . . . . . . . . . . . . . .   9
  252.           Overview . . . . . . . . . . . . . . . . . . . . . . . .   9
  253.           Macro Structure  . . . . . . . . . . . . . . . . . . . .   9
  254.           Macro Functions  . . . . . . . . . . . . . . . . . . . .  10
  255.           Macro Labels . . . . . . . . . . . . . . . . . . . . . .  12
  256.           Macro Variables  . . . . . . . . . . . . . . . . . . . .  13
  257.           How to Use Variables . . . . . . . . . . . . . . . . . .  14
  258.           Reserved Variables . . . . . . . . . . . . . . . . . . .  15
  259.           Executing Macros . . . . . . . . . . . . . . . . . . . .  16
  260.           Additional Macro Execution Rules . . . . . . . . . . . .  16
  261.           Cancelling a Macro . . . . . . . . . . . . . . . . . . .  17
  262.           A Macro Example in Detail  . . . . . . . . . . . . . . .  17
  263.  
  264.      Description of Functions (Alphabetical) . . . . . . . . . . .  21
  265.           ABAUd  . . . . . . . . . . . . . . . . . . . . . . . . .  21
  266.           ALARm  . . . . . . . . . . . . . . . . . . . . . . . . .  21
  267.           ASCIiup  . . . . . . . . . . . . . . . . . . . . . . . .  22
  268.           AUTO . . . . . . . . . . . . . . . . . . . . . . . . . .  23
  269.           BEEP . . . . . . . . . . . . . . . . . . . . . . . . . .  24
  270.           BREAk  . . . . . . . . . . . . . . . . . . . . . . . . .  24
  271.           CALL . . . . . . . . . . . . . . . . . . . . . . . . . .  24
  272.           CALOok . . . . . . . . . . . . . . . . . . . . . . . . .  25
  273.           CAPMode  . . . . . . . . . . . . . . . . . . . . . . . .  25
  274.           CAPTure  . . . . . . . . . . . . . . . . . . . . . . . .  26
  275.           CHATmode . . . . . . . . . . . . . . . . . . . . . . . .  26
  276.           CLEAr  . . . . . . . . . . . . . . . . . . . . . . . . .  26
  277.           COMPare  . . . . . . . . . . . . . . . . . . . . . . . .  27
  278.           CURSor . . . . . . . . . . . . . . . . . . . . . . . . .  28
  279.           DECRement  . . . . . . . . . . . . . . . . . . . . . . .  28
  280.           DIAL . . . . . . . . . . . . . . . . . . . . . . . . . .  28
  281.                Marking Numbers for Dialing . . . . . . . . . . . .  30
  282.                Automatic Resumption of Dialing . . . . . . . . . .  30
  283.                Testing Success and Failure Results . . . . . . . .  30
  284.                Handling Incoming Calls . . . . . . . . . . . . . .  31
  285.           DISPlay  . . . . . . . . . . . . . . . . . . . . . . . .  32
  286.           DIVIde . . . . . . . . . . . . . . . . . . . . . . . . .  33
  287.           DOORway  . . . . . . . . . . . . . . . . . . . . . . . .  33
  288.           DPARms . . . . . . . . . . . . . . . . . . . . . . . . .  34
  289.           EDIT . . . . . . . . . . . . . . . . . . . . . . . . . .  34
  290.           ELAPse . . . . . . . . . . . . . . . . . . . . . . . . .  35
  291.           EXECute  . . . . . . . . . . . . . . . . . . . . . . . .  35
  292.                Using the Direct Switch: EXEC-D . . . . . . . . . .  37
  293.                Using the Swap to Disk Switch: EXEC-S . . . . . . .  38
  294.                EXECute Preview Mode  . . . . . . . . . . . . . . .  38
  295.           EXIT . . . . . . . . . . . . . . . . . . . . . . . . . .  39
  296.           GETString  . . . . . . . . . . . . . . . . . . . . . . .  39
  297.           GOLOok . . . . . . . . . . . . . . . . . . . . . . . . .  41
  298.  
  299.  
  300.  
  301.                    {COMMO} (tm)  Macro Programming Guide             7
  302.  
  303.  
  304.           GOTO . . . . . . . . . . . . . . . . . . . . . . . . . .  42
  305.           HANGup . . . . . . . . . . . . . . . . . . . . . . . . .  42
  306.           HELP . . . . . . . . . . . . . . . . . . . . . . . . . .  42
  307.           HFLOw  . . . . . . . . . . . . . . . . . . . . . . . . .  42
  308.           HOLD . . . . . . . . . . . . . . . . . . . . . . . . . .  43
  309.           IFCArrier  . . . . . . . . . . . . . . . . . . . . . . .  43
  310.           IFCOndition  . . . . . . . . . . . . . . . . . . . . . .  44
  311.           IFERrorlevel . . . . . . . . . . . . . . . . . . . . . .  45
  312.           IFEXist  . . . . . . . . . . . . . . . . . . . . . . . .  46
  313.           INCRement  . . . . . . . . . . . . . . . . . . . . . . .  46
  314.           INITmodem  . . . . . . . . . . . . . . . . . . . . . . .  47
  315.           INPUt  . . . . . . . . . . . . . . . . . . . . . . . . .  47
  316.           INSTring . . . . . . . . . . . . . . . . . . . . . . . .  48
  317.           KEYStuff . . . . . . . . . . . . . . . . . . . . . . . .  48
  318.           LENGth . . . . . . . . . . . . . . . . . . . . . . . . .  49
  319.           LIGHts . . . . . . . . . . . . . . . . . . . . . . . . .  49
  320.           LOCAlecho  . . . . . . . . . . . . . . . . . . . . . . .  50
  321.           LOOKfor  . . . . . . . . . . . . . . . . . . . . . . . .  50
  322.           MACLoad  . . . . . . . . . . . . . . . . . . . . . . . .  52
  323.           MACRo  . . . . . . . . . . . . . . . . . . . . . . . . .  53
  324.           MARK . . . . . . . . . . . . . . . . . . . . . . . . . .  54
  325.           MENU . . . . . . . . . . . . . . . . . . . . . . . . . .  55
  326.           MULTiply . . . . . . . . . . . . . . . . . . . . . . . .  57
  327.           NOCArrier  . . . . . . . . . . . . . . . . . . . . . . .  58
  328.           NOOP . . . . . . . . . . . . . . . . . . . . . . . . . .  58
  329.           OFFLog . . . . . . . . . . . . . . . . . . . . . . . . .  58
  330.           PARMs  . . . . . . . . . . . . . . . . . . . . . . . . .  59
  331.           PASSword . . . . . . . . . . . . . . . . . . . . . . . .  59
  332.           PAUSe  . . . . . . . . . . . . . . . . . . . . . . . . .  60
  333.           POPStack . . . . . . . . . . . . . . . . . . . . . . . .  60
  334.           PRINtlog . . . . . . . . . . . . . . . . . . . . . . . .  60
  335.           PUSHstack  . . . . . . . . . . . . . . . . . . . . . . .  61
  336.           RCLOse . . . . . . . . . . . . . . . . . . . . . . . . .  61
  337.           READ . . . . . . . . . . . . . . . . . . . . . . . . . .  62
  338.           RETUrn . . . . . . . . . . . . . . . . . . . . . . . . .  63
  339.           ROPEn  . . . . . . . . . . . . . . . . . . . . . . . . .  63
  340.           RTRAn  . . . . . . . . . . . . . . . . . . . . . . . . .  64
  341.           RXMOdem  . . . . . . . . . . . . . . . . . . . . . . . .  65
  342.           RYMOdem  . . . . . . . . . . . . . . . . . . . . . . . .  66
  343.           SCREen . . . . . . . . . . . . . . . . . . . . . . . . .  67
  344.           SCROllback . . . . . . . . . . . . . . . . . . . . . . .  68
  345.           SEND . . . . . . . . . . . . . . . . . . . . . . . . . .  68
  346.           SETDial  . . . . . . . . . . . . . . . . . . . . . . . .  68
  347.           SETEsc . . . . . . . . . . . . . . . . . . . . . . . . .  69
  348.           SETGet . . . . . . . . . . . . . . . . . . . . . . . . .  70
  349.           SETLook  . . . . . . . . . . . . . . . . . . . . . . . .  71
  350.           SETVariable  . . . . . . . . . . . . . . . . . . . . . .  73
  351.           SFLOw  . . . . . . . . . . . . . . . . . . . . . . . . .  74
  352.           SHELl  . . . . . . . . . . . . . . . . . . . . . . . . .  75
  353.           SIGNal . . . . . . . . . . . . . . . . . . . . . . . . .  75
  354.           SOUNd  . . . . . . . . . . . . . . . . . . . . . . . . .  76
  355.           SPDCtrl  . . . . . . . . . . . . . . . . . . . . . . . .  76
  356.  
  357.  
  358.  
  359.                    {COMMO} (tm)  Macro Programming Guide             8
  360.  
  361.  
  362.           SPOCtrl  . . . . . . . . . . . . . . . . . . . . . . . .  77
  363.           SSLOok . . . . . . . . . . . . . . . . . . . . . . . . .  77
  364.           STATusline . . . . . . . . . . . . . . . . . . . . . . .  78
  365.           STOP . . . . . . . . . . . . . . . . . . . . . . . . . .  78
  366.           STRAn  . . . . . . . . . . . . . . . . . . . . . . . . .  79
  367.           SUBString  . . . . . . . . . . . . . . . . . . . . . . .  80
  368.           SXMOdem  . . . . . . . . . . . . . . . . . . . . . . . .  80
  369.           SYMOdem  . . . . . . . . . . . . . . . . . . . . . . . .  81
  370.           TOGGles  . . . . . . . . . . . . . . . . . . . . . . . .  82
  371.           UNMArk . . . . . . . . . . . . . . . . . . . . . . . . .  83
  372.           VIDEo  . . . . . . . . . . . . . . . . . . . . . . . . .  83
  373.           VTCUr  . . . . . . . . . . . . . . . . . . . . . . . . .  84
  374.           VTPAd  . . . . . . . . . . . . . . . . . . . . . . . . .  84
  375.           WCLOse . . . . . . . . . . . . . . . . . . . . . . . . .  84
  376.           WOPEn  . . . . . . . . . . . . . . . . . . . . . . . . .  85
  377.           WRITe  . . . . . . . . . . . . . . . . . . . . . . . . .  85
  378.  
  379.      Appendix A   Table of {COMMO} Key-labels  . . . . . . . . . .  87
  380.           Enhanced Keyboard Key-labels . . . . . . . . . . . . . .  88
  381.  
  382.      Appendix B   List of Reserved Variables . . . . . . . . . . .  89
  383.  
  384.      Appendix C   Macro Functions Listed by Class  . . . . . . . .  91
  385.  
  386.  
  387.  
  388.                    {COMMO} (tm)  Macro Programming Guide             9
  389.  
  390.  
  391.      ==========================
  392.      Programming {COMMO} Macros
  393.      ==========================
  394.  
  395.      IMPORTANT!  Please read the next few pages before you attempt to
  396.      write any macros!  The rules for writing {COMMO} macros are few
  397.      in number, but must be followed carefully.
  398.  
  399.      Examples of more complex macro programming are given in the
  400.      sample Macro File COMMO.MAC, in the supplied file SAMPLES.MAC and
  401.      in the Host Mode and Guide macros.  A macro from SAMPLES.MAC is
  402.      discussed in detail at the end of this section.
  403.  
  404.      The following pages assume familiarity with {COMMO}'s key
  405.      commands and with other features of the program.  Since many
  406.      macro functions have corresponding key commands, duplicate
  407.      explanations will not be given here.  Refer to the description of
  408.      the key command in the User Guide and Reference.
  409.  
  410.  
  411.      Overview
  412.      ========
  413.  
  414.      {COMMO}'s Macro File may contain any number of macros.  The only
  415.      size limitation on the file is that the Dialing Directory and
  416.      Macro File combined must total 64k bytes or less.
  417.  
  418.      Macros are "interpreted," which implies the following:
  419.  
  420.           (1)  Macros are not processed until they are executed.
  421.  
  422.           (2)  Only macros within the currently loaded Macro File are
  423.                available for use.
  424.  
  425.           (3)  Macros added or modified with the Internal Editor are
  426.                available immediately.
  427.  
  428.      Alternate Macro Files may be loaded using the MACLoad function
  429.      (the original file is replaced and may be reloaded at a later
  430.      time).
  431.  
  432.  
  433.      Macro Structure
  434.      ===============
  435.  
  436.      Macros consist of a series of items enclosed in curly braces. 
  437.      Items may be placed on the same line or on as many lines as
  438.      desired.  The file is entirely free-form.  Lines may be up to 255
  439.      characters in length and all text outside the curly braces is
  440.      commentary and is ignored by the Macro Processor.
  441.  
  442.      There are two types of items: "functions" and "labels."
  443.  
  444.  
  445.  
  446.                    {COMMO} (tm)  Macro Programming Guide            10
  447.  
  448.  
  449.  
  450.           Functions are action items.  Some are equivalent to {COMMO}
  451.           key commands, such as DIAL, while others are unique to the
  452.           macro language, such as SETVariable.
  453.  
  454.           Labels are macro entry points and may be placed anywhere
  455.           within the Macro File.
  456.  
  457.  
  458.      Macro Functions
  459.      ===============
  460.  
  461.      Each macro function is described in detail later in this
  462.      document.  See also Appendix C "Macro Functions Listed by Class."
  463.  
  464.  
  465.      The general form of any macro function is:
  466.  
  467.           {name-switches arg1,arg2,...,argn}
  468.  
  469.                name      The function name describes the action to be
  470.                          performed and consists of four or more
  471.                          characters. Only the first four are
  472.                          significant and case is ignored.
  473.  
  474.                switches  These are used to alter the operation of a
  475.                          function.  Each switch is a single letter and
  476.                          may be followed by a numeric value, usually
  477.                          "1" or "0" to indicate "yes" or "no"
  478.                          respectively.
  479.  
  480.                          Switches have default interpretations when
  481.                          the numeric value is omitted, or when the
  482.                          switch is not present.
  483.  
  484.                          Switches must be separated from the name with
  485.                          a hyphen (no intervening spaces).  They may
  486.                          be upper or lower case.
  487.  
  488.                          See individual function descriptions for
  489.                          details (note that only certain functions
  490.                          have switches).
  491.  
  492.                args      A SINGLE SPACE separates the arguments from
  493.                          the function name and switches
  494.  
  495.                          Individual arguments are separated with
  496.                          commas and may contain no extraneous spaces
  497.                          (all spaces are significant).
  498.  
  499.      NOTE:  Curly braces may be represented within macro functions by
  500.      using ^( for { and ^) for }.
  501.  
  502.  
  503.  
  504.                    {COMMO} (tm)  Macro Programming Guide            11
  505.  
  506.  
  507.  
  508.      Examples:
  509.  
  510.           {send Hi, how are you?}
  511.  
  512.                This function sends the string "Hi, how are you?" to
  513.                the modem.  SEND has only one argument -- the string to
  514.                send out.  Since the string is the last argument, it
  515.                may contain commas and spaces.  Quotes are not used to
  516.                define strings.
  517.  
  518.           {ifcon-LE label1,label2}
  519.  
  520.                The IFCOndition function tests for conditions set by
  521.                other functions, such as COMPare.  Here two switches
  522.                are present, telling {COMMO} to test for less than or
  523.                equal:
  524.  
  525.                     L    Test for "less than."
  526.                     E    Test for "equal."
  527.  
  528.                The two arguments are labels to GOTO depending on the
  529.                conditions.
  530.  
  531.                Notice that "name-switches" may be written in a number
  532.                of different ways:
  533.  
  534.                     ifco-LE  ifcondition-EL  ifcond-LE
  535.  
  536.           {asci-S0E1 pathname}
  537.  
  538.                The ASCII Upload function will send the file indicated
  539.                by "pathname."  The switches override current settings
  540.                and tell {COMMO}:
  541.  
  542.                     S0   Do NOT strip linefeeds.
  543.                     E1   DO expand blank lines (may also be written
  544.                          "E").
  545.  
  546.           {sound}   {sound yes}
  547.  
  548.                The first function will TOGGLE Master Sound ON/OFF
  549.                (since there is no argument).  The second will turn the
  550.                sound ON.
  551.  
  552.  
  553.      One very important function is the STOP function.  It is used to
  554.      terminate macro processing and may appear in either its long form
  555.      or short form:
  556.  
  557.           ... {stop}          long form
  558.           ... {}              short form
  559.  
  560.  
  561.  
  562.                    {COMMO} (tm)  Macro Programming Guide            12
  563.  
  564.  
  565.  
  566.      Macro processing continues until a STOP function is executed.  Be
  567.      sure to use one or processing will continue into the next macro
  568.      in the Macro File!
  569.  
  570.  
  571.      Macro Labels
  572.      ============
  573.  
  574.      Labels are identifiers consisting of one or more characters. 
  575.      When a label is defined, it must be preceded by a colon. 
  576.      References to labels, such as {goto label}, do not require the
  577.      colon.
  578.  
  579.      IMPORTANT!  {COMMO} always searches for labels from the beginning
  580.      of the Macro File.  This means that if a label is duplicated
  581.      within the file, the first occurrence will be used.
  582.  
  583.      Only the first eight characters in a label are significant.  Case
  584.      is ignored.  All characters are allowed in labels except the
  585.      following:
  586.  
  587.           colon          ":"
  588.           space          " "
  589.           comma          ","
  590.           slash          "/"
  591.           curly braces   "{" or "}"
  592.  
  593.      Examples:
  594.  
  595.           {:mailrun} {call login} ...
  596.  
  597.           {:start-here} {:another.entry} {send Begin now!} ...
  598.  
  599.  
  600.      A number of three character labels are reserved and are called
  601.      "key-labels."  When the corresponding key is pressed from the
  602.      Terminal Screen, {COMMO} will look for the key-label in the
  603.      current Macro File.  If the key-label is found, macro processing
  604.      will begin at that location.
  605.  
  606.      Any default key assignment may be overridden using a key-label. 
  607.      For example, pressing Alt-D normally enters the Dialing
  608.      Directory.  But suppose this line is in the Macro File:
  609.  
  610.           {:ald} {clear} {}
  611.  
  612.      Now pressing Alt-D will clear the screen.
  613.  
  614.      See Appendix A "Table of {COMMO} Key-labels" for a complete list
  615.      of keys that may be assigned.
  616.  
  617.  
  618.  
  619.                    {COMMO} (tm)  Macro Programming Guide            13
  620.  
  621.  
  622.  
  623.      Macro Variables
  624.      ===============
  625.  
  626.      {COMMO} maintains a String Variable Space in which variables
  627.      appear in the form:
  628.  
  629.           name,string
  630.  
  631.                name      An identifier consisting of one or more
  632.                          characters of which only the first eight are
  633.                          significant.  Case is ignored.  The following
  634.                          are the ONLY valid characters that may be
  635.                          used in a variable name:
  636.  
  637.                               "A" through "Z"
  638.                               "a" through "z"
  639.                               "0" through "9"
  640.                               "_" underline.
  641.  
  642.                          All other characters will terminate the name.
  643.  
  644.                string    A text string.  The string must not contain
  645.                          any control characters below ASCII 28.  If a
  646.                          string is set to null (0 characters), it is
  647.                          deleted from variable space.
  648.  
  649.                          NOTE:  Any variable not defined is considered
  650.                          to be null.
  651.  
  652.                          Strings consisting of only the digits 0-9 and
  653.                          representing a decimal number from 0 to 65535
  654.                          are also numeric variables (there is no other
  655.                          difference between string and numeric
  656.                          variables).
  657.  
  658.                          The maximum length of strings is 240
  659.                          characters.
  660.  
  661.      The String Variable Space may be viewed from within the Macro
  662.      Processor window by pressing "V".  The amount of unused string
  663.      space is shown at the bottom of the screen.
  664.  
  665.      Once a variable is defined, it remains in String Variable Space
  666.      until it is redefined or deleted (set to null).  Therefore
  667.      variables should be deleted or re-used to prevent String Variable
  668.      Space from becoming full.
  669.  
  670.      The default size of String Variable Space is 1536 bytes, but it
  671.      may be adjusted with the "/v" command line switch at program
  672.      startup.  The valid range is from 512 bytes to 65535 bytes.  See
  673.      also "Command Line Options" in the User Guide and Reference.
  674.  
  675.  
  676.  
  677.                    {COMMO} (tm)  Macro Programming Guide            14
  678.  
  679.  
  680.  
  681.  
  682.      How to Use Variables
  683.      ====================
  684.  
  685.      {COMMO} variables are set (or "defined") by various macro
  686.      functions and by variable strings in a Dialing Directory entry.
  687.  
  688.      Variables are used (or "referenced") in macro function arguments
  689.      and in the telephone number field of the Dialing Directory.  
  690.  
  691.      See also "Alt-D  Dialing Directory" in the User Guide and
  692.      Reference.
  693.  
  694.      When a variable name appears, the string assigned to the name is
  695.      substituted for the name.  If the variable is null, then the name
  696.      is replaced with 0 characters.  {COMMO} will expand the variables
  697.      in a macro function before processing it.
  698.  
  699.      In order to distinguish variable names, they must be preceded
  700.      with a percent sign "%" (use two percent signs if a percent sign
  701.      is needed in the data).
  702.  
  703.      The end of the variable name is indicated with another "%" or
  704.      with the first character that is not allowed in a name (see list
  705.      of characters above).
  706.  
  707.  
  708.      A variable definition example:
  709.  
  710.           {setvar animal,Elephant} or {setvar %animal,Elephant}
  711.  
  712.                Notice that the "%" is not required (but is permitted)
  713.                when the variable name is the first argument of a
  714.                function that defines, modifies or tests the value of a
  715.                variable.  Other such functions include INPUt,
  716.                GETString, INCRement, DECRement, COMPare, SUBString,
  717.                INSTring, READ.
  718.  
  719.                If the variable name in this situation needs to be a
  720.                variable, then use two percent signs:
  721.  
  722.                     {setv %%animal,Elephant}
  723.  
  724.  
  725.      Variable usage examples:
  726.  
  727.           {setvar animal,Elephant}
  728.           {send %animal}           Sends "Elephant" to the modem.
  729.           {send animal}            Sends "animal".
  730.           {send %animal%s are large animals}
  731.  
  732.  
  733.  
  734.                    {COMMO} (tm)  Macro Programming Guide            15
  735.  
  736.  
  737.                                    Sends "Elephants are large
  738.                                    animals".  Note that the trailing
  739.                                    "%" is required here.
  740.  
  741.           {setvar animal,Elephant}
  742.           {setv creature,animal}
  743.           {send creature}          Sends "creature". 
  744.           {send %creature}         Sends "animal". 
  745.           {setv %%creature,Giraffe}
  746.           {send %animal}           Sends "Giraffe".
  747.  
  748.  
  749.      IMPORTANT!  Variables may NOT be substituted within the function
  750.      name or switches.  They may be substituted anywhere else, even
  751.      for the commas separating arguments.
  752.  
  753.  
  754.      Reserved Variables
  755.      ==================
  756.  
  757.      Certain variables have fixed names so that {COMMO} can find them
  758.      whenever they are needed.  The names of these variables begin
  759.      with an underline character "_".  There are two types of reserved
  760.      variables: "user-defined" and "built-in" (see Appendix B "List of
  761.      Reserved Variables" for a complete list).
  762.  
  763.      USER-DEFINED reserved variables are defined in the same way that
  764.      you define ordinary variables -- in the Setup File using SET, or
  765.      in a macro using functions such as SETVariable, INPUt, etc. 
  766.      These variables define strings used by certain program features. 
  767.      For example, the pathname of the Usage Log is defined in the
  768.      Setup File as follows:
  769.  
  770.           {set _uselog,c:\commo\commo.log}
  771.  
  772.      BUILT-IN variables are defined by {COMMO} based on current system
  773.      parameters.  Examples are:
  774.  
  775.           _cap      Current Capture File pathname
  776.           _tim      Current time of day
  777.  
  778.      Any variable that starts with the same four characters as a
  779.      built-in variable ("_" plus the next three) will be considered
  780.      the same variable.  For example "_pas" may be written "_password"
  781.      and "_yea" may be written "_year".
  782.  
  783.      {COMMO} will always search String Variable Space first when
  784.      looking up the value of any variable.  This allows built-in
  785.      variables to be overridden, but only when using their four
  786.      character minimum names.  For example, to override the serial
  787.      port number, you must use "_por", not "_port".
  788.  
  789.  
  790.  
  791.                    {COMMO} (tm)  Macro Programming Guide            16
  792.  
  793.  
  794.      See Appendix B for a complete list of reserved variables.
  795.  
  796.  
  797.      Executing Macros
  798.      ================
  799.  
  800.      Macro execution may be started in any of the following ways:
  801.  
  802.      1)   Open the Macro Processor window by pressing Alt-M.  Position
  803.           the Selector Bar at the desired starting point and press
  804.           [Enter].  The Macro Processor will begin processing at the
  805.           first macro label or function on the line.
  806.  
  807.           NOTE:  Macros started with the Selector Bar do not need
  808.           macro labels and may be started at any point within the
  809.           macro.
  810.  
  811.      2)   If a macro label is also a key-label, then you may press
  812.           that key from the Terminal Screen.  Note that if the same
  813.           key-label appears more than once, the first occurrence will
  814.           be used.
  815.  
  816.      3)   A macro may be linked to a Dialing Directory entry (Linked
  817.           Macro).  In this case {COMMO} will GOTO the macro when a
  818.           connection is established with that system (or optionally
  819.           CALL it, see the DIAL function).
  820.  
  821.      4)   A startup macro may be specified in the Setup File using the
  822.           "{mac=label}" item.
  823.  
  824.      5)   A startup macro may be specified on the command line with
  825.           the switch "/:label".  This will override the Setup File
  826.           macro.
  827.  
  828.      6)   A macro may be an argument of another function such as CALL,
  829.           GOTO, DIAL or SETLook.
  830.  
  831.      Some macro functions show their current action on the Status Line
  832.      at the bottom of the screen.  In addition, a "face" character in
  833.      the middle of the Status Line indicates that a macro is
  834.      executing.
  835.  
  836.  
  837.      Additional Macro Execution Rules
  838.      ================================
  839.  
  840.      Characters may be typed to the serial port during functions that
  841.      wait (LOOKfor, GETString, PAUSe, HOLD, etc.).  Command keys will
  842.      be ignored during macro processing.
  843.  
  844.      The Macro Processor will execute functions IN SEQUENCE until one
  845.      of the following conditions occurs:
  846.  
  847.  
  848.  
  849.                    {COMMO} (tm)  Macro Programming Guide            17
  850.  
  851.  
  852.  
  853.      1)   A CALL, GOTO, RETURn, STOP, EXIT, etc. is encountered.
  854.  
  855.      2)   Control is transferred to an alternate macro from certain
  856.           functions when a special condition occurs.  An example of
  857.           this is the SETLook function.  The alternate will execute
  858.           when a subsequent LOOKfor times out.
  859.  
  860.      3)   A macro error occurs.  This will bring up the Macro
  861.           Processor window with the Selector Bar on the problem line. 
  862.           The macro will be terminated.
  863.  
  864.      4)   The end of the Macro File is reached.
  865.  
  866.  
  867.      Cancelling a Macro
  868.      ==================
  869.  
  870.      The [Esc] key is used to terminate macro processing.  To send an
  871.      <esc> code (ASCII 27) to the remote during macro execution
  872.      (without terminating the macro), press Ctrl-[ (Ctrl + left
  873.      bracket).
  874.  
  875.      Current function execution may be terminated by pressing
  876.      [Ctrl-Break].  For example, this can be used to terminate a
  877.      LOOKfor, PAUSe or HOLD prematurely.  Macro processing will
  878.      advance to the next function.
  879.  
  880.      If a macro contains a function that brings up a {COMMO} window
  881.      (Dialing Directory, Capture File Options, etc.), then [Esc] will
  882.      exit the window and processing continues with the next function. 
  883.      To terminate macro processing from a window, press [Ctrl-Break].
  884.  
  885.      NOTE:  The SETEsc function may be used to help prevent accidental
  886.      termination of macros.
  887.  
  888.  
  889.      A Macro Example in Detail
  890.      =========================
  891.  
  892.      The following macro example from SAMPLES.MAC can be used to log
  893.      in to many types of Bulletin Board Systems.  This is a Linked
  894.      Macro, so the label "login" would appear in the Dialing Directory
  895.      macro field for each system that uses it.  When you dial and
  896.      connect to one of the systems, {COMMO} will automatically GOTO
  897.      the macro.
  898.  
  899.      The subroutine "gls" (generic login subroutine) can also be
  900.      called from macros that perform mailruns and other BBS
  901.      operations.
  902.  
  903.  
  904.  
  905.                    {COMMO} (tm)  Macro Programming Guide            18
  906.  
  907.  
  908.      Note that labels and functions may be placed side by side on the
  909.      same line (up to 255 characters).  For purposes of this example
  910.      each item is placed on its own line.
  911.  
  912.      The main routine at "login" performs some initial functions and
  913.      then calls the subroutine at "gls".  The subroutine looks for
  914.      various prompts, responds to them and terminates after responding
  915.      to the "password" prompt.
  916.  
  917.  
  918.      {:login}
  919.  
  920.                The entry point.  All labels begin with a ":".
  921.  
  922.           {capture y,c:\commo\commo.cap}
  923.  
  924.                "y" means open the Capture File.  The pathname of the
  925.                file is specified here, otherwise the current file
  926.                would be opened.
  927.  
  928.           {asci ,}
  929.  
  930.                Set ASCII Upload to "no pacing."
  931.  
  932.           {call gls}
  933.  
  934.                CALL the macro at "gls".  When the subroutine executes
  935.                a RETUrn, control will come back here.
  936.  
  937.           {}
  938.  
  939.                STOP and resume manual operation in the Terminal
  940.                Screen.  Without this STOP processing would continue
  941.                into subsequent macros.  Remember that labels are
  942.                "passed over" during sequential macro processing.
  943.  
  944.      {:gls}
  945.  
  946.                The entry point of the "gls" subroutine.
  947.  
  948.           {setlook 60,hng,10,|}
  949.  
  950.                This function specifies parameters that go into effect
  951.                whenever a LOOKfor executes.  It tells the Macro
  952.                Processor to wait up to 60 seconds for the string (or
  953.                strings) and to GOTO the label "hng" if none of the
  954.                strings appear within that time.  The timer is
  955.                restarted each time a LOOKfor begins to execute.
  956.  
  957.                The SETLook also specifies that a "|" (carriage return)
  958.                should be sent to the modem whenever 10 seconds have
  959.                elapsed and no characters are received.  This is used
  960.  
  961.  
  962.  
  963.                    {COMMO} (tm)  Macro Programming Guide            19
  964.  
  965.  
  966.                to respond to prompts that are not explicitly specified
  967.                in SSLOoks/CALOoks/GOLOoks/LOOKfors (e.g., "Press any
  968.                key to continue").
  969.  
  970.                Use this latter facility with care since a BBS may
  971.                spend time processing and not actually be expecting
  972.                input from the caller.  The carriage returns sent will
  973.                accumulate and be used to satisfy later prompts,
  974.                causing things to get out of "sync."  Adjust the 10
  975.                second timeout as needed.
  976.  
  977.           {setv ss_r,~|}
  978.           {setv ss_yr,~y|}
  979.  
  980.                Variables are set for some common responses.  They will
  981.                be used later by SSLOok functions.  For convenience,
  982.                these variables may be defined in the Setup File (using
  983.                the "set" keyword).
  984.  
  985.                SSLOoks, CALOoks and GOLOoks store strings to look for,
  986.                but do not wait for the strings (only a LOOKfor can do
  987.                the actual waiting).
  988.  
  989.      {:li1}
  990.           {sslo ss_r,(enter)}
  991.           {sslo ss_yr,graphics (enter)}
  992.           {sslo ss_yr,is this correct} 
  993.  
  994.                The SSLOoks will send the strings in the variables when
  995.                the respective targets are received.  The looking for
  996.                all of the stored strings then resumes.
  997.  
  998.           {calo li1,li2,first name}
  999.           {calo li1,li3,last name}
  1000.  
  1001.                CALOoks will CALL the second label if the target string
  1002.                appears (the LOOKfor is cancelled).  When the macro
  1003.                executes a RETUrn, control goes to the first label
  1004.                where all of the strings can be set up again.  Note
  1005.                that CALOoks are used here for demonstration.  SSLOoks
  1006.                could be used as well (and probably should be).
  1007.  
  1008.           {golo li1,;passwor}
  1009.  
  1010.                A GOLOok will set up a string and GOTO the label if the
  1011.                string appears (only one label is used).  In this
  1012.                example the specified string is to be ignored.  This
  1013.                was needed for a BBS that used the string
  1014.                "first;last;password" prior to the actual password
  1015.                prompt.
  1016.  
  1017.           {lookfor password}
  1018.  
  1019.  
  1020.  
  1021.                    {COMMO} (tm)  Macro Programming Guide            20
  1022.  
  1023.  
  1024.  
  1025.                This is where the actual "looking" takes place. 
  1026.                Remember that SSLOoks, CALOoks and GOLOoks only cause
  1027.                strings to be stored but do not actually wait for the
  1028.                strings.
  1029.  
  1030.                The LOOKfor will wait for the string specified and also
  1031.                any other stored strings (up to 16 total).  If the
  1032.                string in the LOOKfor appears, control passes to the
  1033.                next macro function.
  1034.  
  1035.                "password" is assumed to be the last prompt in the
  1036.                login sequence.
  1037.  
  1038.           {send ~%_pas|}
  1039.  
  1040.                Control then passes here and the string is sent to the
  1041.                modem.  The tilde (~) causes a half-second delay before
  1042.                sending the password.  The password in the Dialing
  1043.                Directory entry was stored into the built-in variable
  1044.                "_pas" when dialing began.
  1045.  
  1046.                Finally, a carriage return (|) is sent.
  1047.  
  1048.           {return}
  1049.  
  1050.                This will RETUrn to the "login" macro.
  1051.  
  1052.      {:li2}
  1053.           {send ~Fred|}
  1054.  
  1055.                Response to "first name".
  1056.  
  1057.           {return}
  1058.  
  1059.      {:li3}
  1060.           {send ~Brucker|}
  1061.  
  1062.                Response to "last name".
  1063.  
  1064.           {return}
  1065.  
  1066.  
  1067.  
  1068.                    {COMMO} (tm)  Macro Programming Guide            21
  1069.  
  1070.  
  1071.      =======================================
  1072.      Description of Functions (Alphabetical)
  1073.      =======================================
  1074.  
  1075.      The purpose of this section is to show the syntax of each
  1076.      function and the meaning of its arguments through examples.  All
  1077.      functions are listed here, but details on functions which are
  1078.      also default key commands are found in The User Guide and
  1079.      Reference under "{COMMO} Key Commands."
  1080.  
  1081.      Function names are shown with their four-letter abbreviations in
  1082.      uppercase.
  1083.  
  1084.      For consistency, the following conventions are used in many
  1085.      functions:
  1086.  
  1087.           "y" or "yes" is used to indicate "yes", "on",  "open",  etc.
  1088.           "n" or "no"  is used to indicate "no",  "off", "close", etc.
  1089.  
  1090.      _____
  1091.  
  1092.      ABAUd
  1093.      _____
  1094.  
  1095.      Default key:   none
  1096.      Description:   Set AutoBaud toggle.
  1097.  
  1098.      Examples:
  1099.  
  1100.           {abaud}             Toggle AutoBaud on/off
  1101.           {abaud y}           Turn on AutoBaud
  1102.           {abaud n}           Turn off AutoBaud
  1103.  
  1104.      _____
  1105.  
  1106.      ALARm
  1107.      _____
  1108.  
  1109.      Default key:   none
  1110.      Description:   Ring the alarm.
  1111.  
  1112.      Examples:
  1113.  
  1114.           {alarm}        Ring alarm, use ring count in Setup File.
  1115.           {alarm 2}      Ring alarm 2 times.
  1116.  
  1117.      {COMMO} will wait until the alarm has stopped ringing before
  1118.      proceeding to the next macro function (the alarm may be
  1119.      terminated early by pressing a key).
  1120.  
  1121.  
  1122.  
  1123.                    {COMMO} (tm)  Macro Programming Guide            22
  1124.  
  1125.  
  1126.      _______
  1127.  
  1128.      ASCIiup
  1129.      _______
  1130.  
  1131.      Default key:   Alt-A
  1132.      Description:   Upload an ASCII (text) file.
  1133.  
  1134.      General form:
  1135.  
  1136.           {ASCIiup pathname[\],pace}
  1137.  
  1138.                pathname       The complete path and filename (if the
  1139.                               path is absent, the current directory
  1140.                               will be used). 
  1141.  
  1142.                               If a path only is used (signified by a
  1143.                               "\" at the end) the ASCII Upload window
  1144.                               will open, prompting you to enter the
  1145.                               filename.
  1146.  
  1147.                pace           The pacing character to be used.
  1148.  
  1149.      Switches:
  1150.  
  1151.                E1 or E   Expand blank lines.  A space will be sent
  1152.                          when a zero-character line is encountered.
  1153.  
  1154.                E0        Do not expand blank lines.
  1155.  
  1156.                S1 or S   Strip linefeeds from outgoing text.
  1157.  
  1158.                S0        Do not strip linefeeds.
  1159.  
  1160.                If a switch is absent, the current setting of the
  1161.                toggle will be used.  The toggles can be set in the
  1162.                Setup File or by using the Alt-T key command.
  1163.  
  1164.                Switches apply to the current function only and do not
  1165.                affect the settings of the toggles.
  1166.  
  1167.      Examples:    
  1168.  
  1169.           {asci}                        Open ASCII Upload window.
  1170.  
  1171.           {asci-S}                      Open ASCII Upload window,
  1172.                                         strip linefeeds when file is
  1173.                                         sent.
  1174.  
  1175.           {asci %uldir%\}               Open ASCII Upload window,
  1176.                                         prompt with the current value
  1177.                                         of the variable "uldir".
  1178.  
  1179.  
  1180.  
  1181.                    {COMMO} (tm)  Macro Programming Guide            23
  1182.  
  1183.  
  1184.  
  1185.           {asci c:\msgs\file.xyz,:}     Upload "file.xyz."  Use ":"
  1186.                                         for pacing.
  1187.  
  1188.           {asci-E0 c:\msgs\file.xyz}    Upload "file.xyz."  Use
  1189.                                         current pacing character, do
  1190.                                         not expand blank lines.
  1191.  
  1192.           {asci c:\msgs\file.xyz,}      Upload "file.xyz."  Do not use
  1193.                                         pacing.
  1194.  
  1195.           {asci ,?}                     Set current pacing character
  1196.                                         to "?"
  1197.  
  1198.           {asci ,}                      Set current pacing to "no"
  1199.                                         pacing.
  1200.  
  1201.      The pacing character may be entered according to the rules shown
  1202.      in Appendix D in the User Guide and Reference.  For example, "^m"
  1203.      or "|" may be used to represent the carriage return.
  1204.  
  1205.      ____
  1206.  
  1207.      AUTO
  1208.      ____
  1209.  
  1210.      Default key:   none
  1211.      Description:   Maintain Auto Receive strings.
  1212.  
  1213.      General form:
  1214.  
  1215.           {AUTO label,string}
  1216.  
  1217.                label          Label to GOTO when the string is
  1218.                               received.
  1219.                string         String to look for, may be up to 32
  1220.                               characters.
  1221.  
  1222.      Examples:
  1223.  
  1224.           {auto}                   Clear all Auto Receive strings.
  1225.           {auto zmodem,^XB00}      Zmodem Auto Receive string.
  1226.  
  1227.      Note that only 8 Auto Receive strings may be in effect at the
  1228.      same time (including any strings defined in the Setup File).
  1229.  
  1230.      Use this function with no arguments to clear all strings when
  1231.      necessary.
  1232.  
  1233.      See also "TIPS on creating LOOKfor strings" under LOOKfor.
  1234.  
  1235.  
  1236.  
  1237.                    {COMMO} (tm)  Macro Programming Guide            24
  1238.  
  1239.  
  1240.      ____
  1241.  
  1242.      BEEP
  1243.      ____
  1244.  
  1245.      Default key:   none
  1246.      Description:   Sound a beep.
  1247.  
  1248.      Example:
  1249.  
  1250.           {beep}              No arguments.
  1251.  
  1252.      _____
  1253.  
  1254.      BREAk
  1255.      _____
  1256.  
  1257.      Default key:   Alt-B
  1258.      Description:   Send a break.
  1259.  
  1260.      Switches:
  1261.  
  1262.                Tn             Set break duration in system clock
  1263.                               ticks.  "n" may range from 1 to 999. 
  1264.                               There are 18.2 clock ticks per second.
  1265.  
  1266.                T0 or T        Set break duration to 18 clock ticks
  1267.                               (default).
  1268.  
  1269.      Examples:
  1270.  
  1271.           {break}             One second break.
  1272.           {break-t9}          One-half second break.
  1273.           {break-t55}         Three second break.
  1274.  
  1275.      ____
  1276.  
  1277.      CALL
  1278.      ____
  1279.  
  1280.      Default key:   none
  1281.      Description:   Execute a macro subroutine.
  1282.  
  1283.      Example:
  1284.  
  1285.           {call abc}          Execute subroutine abc.
  1286.  
  1287.      CALL will push the location following the CALL function onto the
  1288.      macro stack, then it will GOTO the label given in the argument. 
  1289.      When a RETUrn is executed, the location will be popped and
  1290.      control will return to the function following the CALL.
  1291.  
  1292.  
  1293.  
  1294.                    {COMMO} (tm)  Macro Programming Guide            25
  1295.  
  1296.  
  1297.      Note that macros may be nested up to 32 deep.
  1298.  
  1299.      See also RETUrn, PUSHstack, POPStack.
  1300.  
  1301.      ______
  1302.  
  1303.      CALOok
  1304.      ______
  1305.  
  1306.      Default key:   none
  1307.      Description:   Set up an additional string to look for during a
  1308.                     subsequent LOOKfor function.
  1309.  
  1310.      General form:
  1311.  
  1312.           {CALOok label1,label2,target}
  1313.  
  1314.                label1    The location to return to after label2 is
  1315.                          CALLed.
  1316.  
  1317.                label2    The label to CALL when the target is received
  1318.                          from the serial port.
  1319.  
  1320.                target    The ASCII string to look for.  The string
  1321.                          begins following the "," and is terminated by
  1322.                          the "}".
  1323.  
  1324.      CALOok is used in conjunction with LOOKfor.  When the target
  1325.      string appears, a CALL is made to "label2."  When the routine
  1326.      executes a RETUrn, control will pass to "label1".  This is
  1327.      equivalent to:
  1328.  
  1329.           {call label2} {:label1} ...
  1330.  
  1331.      See LOOKfor for details, examples and tips on using CALOok.
  1332.  
  1333.      See also: SSLOok, GOLOok, SETLook.
  1334.  
  1335.      _______
  1336.  
  1337.      CAPMode
  1338.      _______
  1339.  
  1340.      Default key:   none
  1341.      Description:   Set Capture Mode.
  1342.  
  1343.      Examples:
  1344.  
  1345.           {capmode screen}         Set Capture Mode to SCREEN.
  1346.           {capmode filter}         Set Capture Mode to FILTER.
  1347.           {capmode raw}            Set Capture Mode to RAW.
  1348.  
  1349.  
  1350.  
  1351.                    {COMMO} (tm)  Macro Programming Guide            26
  1352.  
  1353.  
  1354.      See also CAPTure.
  1355.  
  1356.      _______
  1357.  
  1358.      CAPTure
  1359.      _______
  1360.  
  1361.      Default key:   Alt-1
  1362.      Description:   Capture File Options.
  1363.  
  1364.      Examples:
  1365.  
  1366.           {capture}                     Open Capture File Options
  1367.                                         window.
  1368.  
  1369.           {capture y}                   Open current Capture File.
  1370.  
  1371.           {capture n}                   Close current Capture File.
  1372.  
  1373.           {capt y,c:\commo\file.xyz}    Open indicated Capture File.
  1374.  
  1375.           {capt n,c:\dl\newfile.cap}    Close current Capture File,
  1376.                                         set new file as indicated.
  1377.  
  1378.      NOTE:  The current Capture File will always be closed when a new
  1379.      file is opened.
  1380.  
  1381.      See also CAPMode.
  1382.  
  1383.      ________
  1384.  
  1385.      CHATmode
  1386.      ________
  1387.  
  1388.      Default key:   Alt-- (Alt minus)
  1389.      Description:   Set Chat Mode toggle.
  1390.  
  1391.      Examples:
  1392.  
  1393.           {chat}              Toggle Chat Mode on/off.
  1394.           {chat y}            Turn on Chat Mode.
  1395.           {chat n}            Turn off Chat Mode
  1396.  
  1397.      _____
  1398.  
  1399.      CLEAr
  1400.      _____
  1401.  
  1402.      Default key:   Alt-C
  1403.      Description:   Clear Terminal Screen to default colors.
  1404.  
  1405.      Example:
  1406.  
  1407.  
  1408.  
  1409.                    {COMMO} (tm)  Macro Programming Guide            27
  1410.  
  1411.  
  1412.  
  1413.           {clear}             No arguments.
  1414.  
  1415.      _______
  1416.  
  1417.      COMPare
  1418.      _______
  1419.  
  1420.      Default key:   none
  1421.      Description:   Compare a string or numeric variable.
  1422.  
  1423.      General form:
  1424.  
  1425.           {COMPare name,string}
  1426.  
  1427.                name           The name of a variable.
  1428.  
  1429.                string         A string of ASCII characters.
  1430.  
  1431.      Examples:
  1432.  
  1433.           {comp pword,aardvark}         Test if the variable "pword"
  1434.                                         is set to "aardvark."
  1435.  
  1436.           {comp pword}                  Test if "pword" is null.
  1437.           {comp pword,}                 Test if "pword" is null.
  1438.  
  1439.           {comp nmbr,5}                 Compare a numeric variable.
  1440.  
  1441.           {comp abc,%xyz}               Test if the variable "abc" is
  1442.                                         equal to the variable "xyz."
  1443.  
  1444.      A numeric variable is a string of ASCII digits, 0-9, forming a
  1445.      positive integer in the range from 0 to 65535.  If the number is
  1446.      outside this range or contains non-numeric characters, the
  1447.      results of the compare will be unpredictable.
  1448.  
  1449.      COMPare will set flags which can be tested with the IFCOndition
  1450.      function.
  1451.  
  1452.           The Condition Flag will be set to "true" if the two
  1453.           arguments are identical strings (case is ignored). 
  1454.           Otherwise it will be set to "false."
  1455.  
  1456.           The Numeric Flag will be set to "equal", "less than" or
  1457.           "greater than."  This flag is unpredictable unless both
  1458.           arguments are valid numeric variables.
  1459.  
  1460.      A variable may be tested for being null (no entry in variable
  1461.      space) by omitting the second argument (or by comparing to a null
  1462.      variable).
  1463.  
  1464.  
  1465.  
  1466.                    {COMMO} (tm)  Macro Programming Guide            28
  1467.  
  1468.  
  1469.      See also IFCOndition.
  1470.  
  1471.      ______
  1472.  
  1473.      CURSor
  1474.      ______
  1475.  
  1476.      Default key:   none
  1477.      Description:   Terminal Screen cursor on/off.
  1478.  
  1479.      Examples:
  1480.  
  1481.           {cursor}            Toggle Terminal cursor on/off.
  1482.           {curs y}            Turn on Terminal Screen cursor.
  1483.           {curs n}            Turn off Terminal Screen cursor.
  1484.  
  1485.      _________
  1486.  
  1487.      DECRement
  1488.      _________
  1489.  
  1490.      Default key:   none
  1491.      Description:   Subtract a number from a numeric variable.
  1492.  
  1493.      Examples:
  1494.  
  1495.           {decr count}        Subtract 1 from the variable "count".
  1496.           {decr apples,200}   Subtract 200 from "apples".
  1497.  
  1498.      Numeric variables and the numbers to be subtracted may range from
  1499.      0 to 65535.  The default number is 1.
  1500.  
  1501.      If the result is less than 0 or if either argument is out of
  1502.      range, then the variable will be set to the string "ERROR".
  1503.  
  1504.      If the variable is not numeric, the results will be
  1505.      unpredictable.
  1506.  
  1507.      See also INCRement.
  1508.  
  1509.      ____
  1510.  
  1511.      DIAL
  1512.      ____
  1513.  
  1514.      Default keys:  Alt-D, Alt-N
  1515.      Description:   Open Dialing Directory, dial marked systems.
  1516.  
  1517.      General form:
  1518.  
  1519.           {DIAL tries,label1,label2}
  1520.  
  1521.  
  1522.  
  1523.                    {COMMO} (tm)  Macro Programming Guide            29
  1524.  
  1525.  
  1526.                tries     The maximum number of dialing tries.  If no
  1527.                          connection is established when the try count
  1528.                          is exhausted, the macro in the second
  1529.                          argument will be started.  May be 0 to 999. 
  1530.                          "0" means unlimited.  Default is 0.
  1531.  
  1532.                label1    A macro to GOTO if the try count in the first
  1533.                          argument is exhausted.  If no macro is
  1534.                          specified or if the macro label is invalid,
  1535.                          control will pass to the next function. 
  1536.                          Default is none.
  1537.  
  1538.                          If the "C" switch is used, the macro will be
  1539.                          CALLed.  When a RETUrn is executed, control
  1540.                          will return to the DIAL function.
  1541.  
  1542.                label2    A macro to GOTO when a response is matched
  1543.                          during the Inter-dial Delay.  Response
  1544.                          strings are listed in the reserved variable
  1545.                          "_dialir" and are usually defined in the
  1546.                          Setup File.
  1547.  
  1548.                          If the "C" switch is used, the macro will be
  1549.                          CALLed.  When a RETUrn is executed, control
  1550.                          will return to the DIAL function.
  1551.  
  1552.      Switches:
  1553.  
  1554.                C1 or C   Specifies that macros will be started via
  1555.                          CALL (instead of GOTO).  When the macros
  1556.                          execute a RETUrn, control returns to the DIAL
  1557.                          function and Multi Number Dialing will
  1558.                          resume.
  1559.  
  1560.                          The "C" switch applies to the Linked Macro
  1561.                          (from the Dialing Directory), the "tries
  1562.                          exhausted" macro and to the Inter-dial Delay
  1563.                          macro.
  1564.  
  1565.                C0        Start dialing macros via GOTO (default).
  1566.  
  1567.      Examples:
  1568.  
  1569.           {dial}              Open Dialing Directory window (similar
  1570.                               to Alt-D).
  1571.  
  1572.           {dial ,}            Multi Number Dial (similar to Alt-N).
  1573.  
  1574.           {dial 25,abc}       Multi Number Dial with try count.
  1575.  
  1576.           {dial-C ,}          Multi Number Dial, CALL Linked Macros.
  1577.  
  1578.  
  1579.  
  1580.                    {COMMO} (tm)  Macro Programming Guide            30
  1581.  
  1582.  
  1583.           {dial-c ,,inter}    Multi Number Dial with Inter-dial Delay
  1584.                               macro.
  1585.  
  1586.  
  1587.      Marking Numbers for Dialing
  1588.      ---------------------------
  1589.  
  1590.      Numbers may be marked in one of several ways:
  1591.  
  1592.           1)   Manually in the Dialing Directory window.
  1593.           2)   By placing Dialing Strings on the {COMMO} command line.
  1594.           3)   Using the MARK macro function.
  1595.  
  1596.      Marked numbers will be redialed in sequence.  If a connection
  1597.      occurs and a valid Linked Macro is specified in the Dialing
  1598.      Directory, the macro will be started via GOTO (unless the "C"
  1599.      switch is present).  If no macro is specified in the Dialing
  1600.      Directory, control is passed to the next function.
  1601.  
  1602.      If no numbers are marked when executing the DIAL, control will
  1603.      pass to the next function.
  1604.  
  1605.  
  1606.      Automatic Resumption of Dialing
  1607.      -------------------------------
  1608.  
  1609.      Here are two methods for resuming at the end of a Linked Macro. 
  1610.      Both allow multiple systems to be called without operator
  1611.      intervention.
  1612.  
  1613.           1)   Use the "C" switch on the DIAL function.  Each Linked
  1614.                Macro should end with a RETUrn which will transfer
  1615.                control back to the DIAL.  When all numbers have been
  1616.                called, control will pass to the function following the
  1617.                DIAL.
  1618.  
  1619.           2)   At the end of each Linked Macro (after logging off),
  1620.                GOTO a macro such as this:
  1621.  
  1622.                     {:nocar} {pause 1} {ifcarrier nocar} {dial ,} {}
  1623.  
  1624.                This ensures that carrier has dropped before DIALing
  1625.                the next number.  The PAUSe allows data to display on
  1626.                the screen while waiting for carrier to drop.
  1627.  
  1628.  
  1629.      Testing Success and Failure Results
  1630.      -----------------------------------
  1631.  
  1632.      Details about a successful or failed dialing attempt are
  1633.      available in several reserved variables (see Appendix B "List of
  1634.      Reserved Variables" for complete descriptions):
  1635.  
  1636.  
  1637.  
  1638.                    {COMMO} (tm)  Macro Programming Guide            31
  1639.  
  1640.  
  1641.  
  1642.           _dtc      Dialing termination code
  1643.           _dialrt   Dialing response text
  1644.           _mod      Speed reported by modem (normally in the CONNECT
  1645.                     or CARRIER response)
  1646.  
  1647.      After a successful attempt the variables "_dialrt" and "_mod" may
  1648.      be tested in your Linked Macro.  For example, if you expected a
  1649.      high-speed connect and the speed reported was 2400 or 1200, then
  1650.      you may want to hang up and try again later.
  1651.  
  1652.      You can get control after each failed attempt by using "DIAL 1",
  1653.      with or without a macro.  For example:
  1654.  
  1655.           1)   {dial-c 1,nocon} ...
  1656.  
  1657.                The Linked Macro and the "no connect" macro will be
  1658.                CALLed (the "C" switch).  The variables "_dtc" and
  1659.                "_dialrt" may be tested in the macro at "nocon".
  1660.  
  1661.           2)   {dial 1} ...
  1662.  
  1663.                Control will pass to the next function if a dialing
  1664.                attempt fails or when no more systems are marked (test
  1665.                "_dtc" to determine which).
  1666.  
  1667.      If the testing indicates that the system should not be dialed
  1668.      again (e.g., it did not answer, _dtc = 3), the UNMArk function
  1669.      can be used with the "L" switch to unmark the last number dialed:
  1670.      {unmark-l}.
  1671.  
  1672.  
  1673.      Handling Incoming Calls
  1674.      -----------------------
  1675.  
  1676.      Most modems return the string "RING" when a call comes in.  If
  1677.      this happens during the Inter-dial Delay, you may choose to stop
  1678.      dialing (to answer a voice call) or to send a brief message to a
  1679.      modem caller (during a BBS event, for example).
  1680.  
  1681.      Use "label2" on the DIAL function to process responses during the
  1682.      Inter-dial Delay.  For example:
  1683.  
  1684.           {dial ,,incoming}
  1685.  
  1686.      The macro at "incoming" will execute if the modem sends an Inter-
  1687.      dial Delay response string (these are normally defined in the
  1688.      Setup File with the "_dialir" variable).
  1689.  
  1690.      See also: SETDial, MARK, UNMArk.
  1691.  
  1692.  
  1693.  
  1694.                    {COMMO} (tm)  Macro Programming Guide            32
  1695.  
  1696.  
  1697.      _______
  1698.  
  1699.      DISPlay
  1700.      _______
  1701.  
  1702.      Default key:   none
  1703.      Description:   Display a string to the screen.
  1704.  
  1705.      General form:
  1706.  
  1707.           {DISPlay row,col,attr,string}
  1708.  
  1709.                row       The row where the string will display.
  1710.                col       The column where the string will display.
  1711.                attr      The attribute (colors) of the string.
  1712.                string    The text of the string (no quotes).
  1713.  
  1714.      Examples:
  1715.  
  1716.           {display 12,20,17,Hello!}     Display "Hello!" at row 12,
  1717.                                         column 20.  Colors are white
  1718.                                         on blue.
  1719.  
  1720.           {disp ,,,Hello, again.^m^j}   Display "Hello, again." at the
  1721.                                         current cursor using the
  1722.                                         current attribute, followed by
  1723.                                         a cr/lf.
  1724.  
  1725.           {disp 3,40}                   Position the cursor at row 3,
  1726.                                         column 40.
  1727.  
  1728.      TIPS on using DISPlay:
  1729.  
  1730.      >    The attribute is specified in the same manner as the colors
  1731.           in the Setup File (press F7 in the Internal Editor to
  1732.           display the Color Chart).
  1733.  
  1734.      >    Setting background colors to high intensity values will
  1735.           cause blinking (for example, using "9" instead of "1" will
  1736.           still give a blue background but the foreground character
  1737.           will blink).  
  1738.  
  1739.      >    After the string is displayed, the previous Terminal Screen
  1740.           attribute will be restored.
  1741.  
  1742.      >    Conversion is performed on the string according to the rules
  1743.           in Appendix D in the User Guide and Reference.
  1744.  
  1745.  
  1746.  
  1747.                    {COMMO} (tm)  Macro Programming Guide            33
  1748.  
  1749.  
  1750.      ______
  1751.  
  1752.      DIVIde
  1753.      ______
  1754.  
  1755.      Default key:   none
  1756.      Description:   Divide a numeric variable by a number.
  1757.  
  1758.      Example:
  1759.  
  1760.           {divi space,1024}        Divide "space" by 1024.
  1761.  
  1762.      Numeric variables may range from 0 to 65535, the divisors may
  1763.      range from 1 to 65535.  The default divisor is 1.
  1764.  
  1765.      The named variable will be set to the quotient, the built-in
  1766.      variable "_rem" will be set to the remainder.
  1767.  
  1768.      If the divisor is zero or if either argument is out of range,
  1769.      then the variable will be set to the string "ERROR".
  1770.  
  1771.      If the variable is not numeric, the results will be
  1772.      unpredictable.
  1773.  
  1774.      _______
  1775.  
  1776.      DOORway
  1777.      _______
  1778.  
  1779.      Default key:   Alt-=
  1780.      Description:   Toggle Doorway Mode.
  1781.  
  1782.      Switches:
  1783.  
  1784.                S1 or S   Status Line on when entering Doorway Mode.
  1785.  
  1786.                S0        Status Line off (default).
  1787.  
  1788.                M0        Do not display Doorway enter/exit messages.
  1789.  
  1790.                M1        Display enter/exit messages (default).
  1791.  
  1792.      Examples:
  1793.  
  1794.           {doorway}           Toggle Doorway Mode on/off.
  1795.           {door-S}            Status Line on when entering Doorway
  1796.                               Mode.
  1797.           {doorway-M0}        Do not display enter/exit messages.
  1798.  
  1799.      The "S" switch is ignored when exiting Doorway Mode (the Status
  1800.      Line will be restored to its prior state).
  1801.  
  1802.  
  1803.  
  1804.                    {COMMO} (tm)  Macro Programming Guide            34
  1805.  
  1806.  
  1807.      ______
  1808.  
  1809.      DPARms
  1810.      ______
  1811.  
  1812.      Default key:   Alt-P
  1813.      Description:   Set Default Dialing Terminal Parameters
  1814.  
  1815.      General form:
  1816.  
  1817.           {DPARms speed,format,comport,terminal-type,delay}
  1818.  
  1819.                speed          The bps rate: 2400, 9600, etc.
  1820.                format         The data format: 8n1, 7e1, etc.
  1821.                comport        The serial port number: 1, 2, 3 or 4.
  1822.                terminal       The terminal-type: A, V or T.
  1823.                delay          The inter-character delay factor: 0-999.
  1824.  
  1825.      Examples:
  1826.  
  1827.           {dparms 2400,8,1,,20}    Set 2400 bps, 8n1, Com1, delay =
  1828.                                    20.
  1829.  
  1830.           {dparms ,,4,V}           Set Com4 VT102.
  1831.  
  1832.           {dparms 19200,7o1}       Set 19200 bps, 7o1.
  1833.  
  1834.      Note that omitted parameters are not changed.
  1835.  
  1836.      See also PARMs.
  1837.  
  1838.      ____
  1839.  
  1840.      EDIT
  1841.      ____
  1842.  
  1843.      Default key:   none
  1844.      Description:   Edit an external file.
  1845.  
  1846.      Example:
  1847.  
  1848.           {edit c:\autoexec.bat}        Edit AUTOEXEC.BAT file.
  1849.  
  1850.      EDIT may be used to edit any text file up to 64k in length.  The
  1851.      rules are the same as for editing a support file with the
  1852.      Internal Editor.
  1853.  
  1854.      TIPS on using EDIT:
  1855.  
  1856.      >    Control characters (below ASCII 28) may not be typed.
  1857.  
  1858.  
  1859.  
  1860.                    {COMMO} (tm)  Macro Programming Guide            35
  1861.  
  1862.  
  1863.      >    Any data beyond the last cr/lf pair will be removed prior to
  1864.           editing.  A cr/lf pair will be added, if necessary, to
  1865.           ensure at least one line in the file.
  1866.  
  1867.      >    The file will be saved unconditionally when Alt-F is pressed
  1868.           or conditionally (if changes were made) when Esc is pressed. 
  1869.           The file is "saved in place" (no backup).
  1870.  
  1871.      ______
  1872.  
  1873.      ELAPse
  1874.      ______
  1875.  
  1876.      Default key:   none
  1877.      Description:   Reset the elapsed timer to 0 minutes.
  1878.  
  1879.      Example:
  1880.  
  1881.           {elap}              No arguments.
  1882.  
  1883.      The elapsed timer is automatically reset whenever dialing begins
  1884.      and when a connection is made with a remote system.
  1885.  
  1886.      _______
  1887.  
  1888.      EXECute
  1889.      _______
  1890.  
  1891.      Default key:   none
  1892.      Description:   Execute a DOS command.
  1893.  
  1894.      Switches:
  1895.  
  1896.                A1 or A   Sound the alarm at the end of command
  1897.                          execution.
  1898.  
  1899.                A0        Do not sound the alarm (default).
  1900.  
  1901.                D1 or D   Execute an external program directly, without
  1902.                          use of the command processor (see details
  1903.                          below).
  1904.  
  1905.                D0        Use the command processor (default).
  1906.  
  1907.                N1 or N   Do not clear the screen before execution. 
  1908.                          This is useful when running programs that
  1909.                          clear or rewrite the screen.  Also for simple
  1910.                          DOS functions like changing directories,
  1911.                          renaming files, etc.  
  1912.  
  1913.                N0        Clear the screen (default).
  1914.  
  1915.  
  1916.  
  1917.                    {COMMO} (tm)  Macro Programming Guide            36
  1918.  
  1919.  
  1920.                S1 or S   Swap to Disk before executing the program
  1921.                          (see details below).
  1922.  
  1923.                S0        Do not swap to disk (default).
  1924.  
  1925.                W         Wait for a key press before restoring the
  1926.                          Terminal Screen.  This is useful if you need
  1927.                          to see the results of the command execution.
  1928.  
  1929.                Wn        Wait for "n" seconds, "n" may range from 0 to
  1930.                          999.  Press a key to cancel the wait.
  1931.  
  1932.                          Note:  Default (no "W" switch) is no wait.
  1933.  
  1934.      Examples:
  1935.  
  1936.           {exec-AW3 dsz port %_por speed %_spe sz %uldir%\%file}
  1937.  
  1938.                {COMMO} will prepare the DSZ command by expanding the
  1939.                "%" variables, then call DOS to execute the program.
  1940.  
  1941.                See the section "Macro Variables" for complete details
  1942.                on variable substitution.
  1943.  
  1944.                The alarm will sound at completion (the "A" switch) and
  1945.                {COMMO} will wait for three seconds (the "W3" switch)
  1946.                before restoring the Terminal Screen.
  1947.  
  1948.           {execute-DN c:\utils\list.com %_cap}
  1949.  
  1950.                The LIST program will be directly executed with the
  1951.                current Capture File pathname as a command line
  1952.                argument.  The screen will not be cleared (LIST will
  1953.                rewrite the screen).  {COMMO} will return immediately
  1954.                to the Terminal Screen when LIST exits.
  1955.  
  1956.      The EXECute function enables you to "build" a command to be
  1957.      executed by DOS.  The DOS command processor (COMMAND.COM) is
  1958.      normally used (see below), which implies that you may specify any
  1959.      command as you would type it from the DOS prompt.
  1960.  
  1961.      Thus you can execute batch files and internal DOS commands (REN,
  1962.      DEL, etc.).  Also you can omit command paths and extensions (if
  1963.      the command is in your PATH or in the current directory).
  1964.  
  1965.      Character conversion is performed in the EXECute function.  This
  1966.      enables you to specify control characters.  For example:
  1967.  
  1968.                {exec echo ^L> prn}   Send a formfeed to the printer
  1969.  
  1970.  
  1971.  
  1972.                    {COMMO} (tm)  Macro Programming Guide            37
  1973.  
  1974.  
  1975.      See Appendix D in the User Guide and Reference for details on
  1976.      conversion.  Note that the vertical bar "|" is NOT translated to
  1977.      a carriage return in the EXECute function.  
  1978.  
  1979.      Key codes may be placed in the keyboard buffer prior to EXECute
  1980.      using the KEYStuff function.
  1981.  
  1982.  
  1983.      Using the Direct Switch: EXEC-D
  1984.      -------------------------------
  1985.  
  1986.      Use this switch to execute .EXE and .COM programs without the use
  1987.      of the command processor (usually COMMAND.COM).
  1988.  
  1989.      The program's Exit Code (called ERRORLEVEL in batch files) is
  1990.      saved and may be tested with the IFERrorlevel function.  The Exit
  1991.      Code is also available in the variable "_err".
  1992.  
  1993.      There are several advantages to using the "D" switch:
  1994.  
  1995.      1)   Only the memory needed to run the program is required (the
  1996.           command processor requires that about 32k be available, even
  1997.           if the program being run is much smaller).
  1998.  
  1999.      2)   About 4k of memory is saved by not having a copy of the
  2000.           command processor resident when the program is running.
  2001.  
  2002.      3)   The program executes faster, since COMMAND.COM is not loaded
  2003.           from disk.
  2004.  
  2005.      4)   The program's Exit Code is preserved and may be tested with
  2006.           the {COMMO} IFERrorlevel function.
  2007.  
  2008.      Two important rules must be followed when using the "D" switch:
  2009.  
  2010.      1)   The full pathname of the program file must be specified,
  2011.           including the path where the file resides on disk and the
  2012.           file extension.  For example:
  2013.  
  2014.                {exec-D c:\util\list.com file.txt}
  2015.  
  2016.      2)   Only .EXE and .COM files may be run (batch files and
  2017.           internal DOS commands cannot be executed without
  2018.           COMMAND.COM).
  2019.  
  2020.  
  2021.  
  2022.                    {COMMO} (tm)  Macro Programming Guide            38
  2023.  
  2024.  
  2025.      Using the Swap to Disk Switch: EXEC-S
  2026.      -------------------------------------
  2027.  
  2028.      The "S" switch will direct {COMMO} to write the program and
  2029.      associated data to a disk file.  This will free up approximately
  2030.      50k to 180k of memory, depending on the sizes of your Variable
  2031.      Space, Scrollback Buffer, Dialing Directory and Macro File.  The
  2032.      pathname of this file is specified with "swp=" in the Setup File
  2033.      (under "Paths and Files").  
  2034.  
  2035.      When the program or shell exits back to {COMMO}, the program and
  2036.      data will be restored from the disk file.  Any errors in this
  2037.      process will cause {COMMO} to exit to DOS.  If the Swap File
  2038.      cannot be opened or there is not enough disk space for the swap,
  2039.      the EXECute (or SHELl) will be attempted without swapping.
  2040.  
  2041.      TIPS on using Swap to Disk:
  2042.  
  2043.      >    The serial port will be closed during the swap (normally it
  2044.           is left open to receive characters during EXECute and
  2045.           SHELl).  To avoid losing any data, swapping should be
  2046.           initiated when the remote system is quiet (or when you are
  2047.           offline).
  2048.  
  2049.      >    Use Swap to Disk when running major applications such as
  2050.           external protocol drivers, offline mail readers, etc.  Using
  2051.           it with internal DOS functions (DEL, COPY, REN, etc.) or
  2052.           very small programs is inefficient and unnecessary.
  2053.  
  2054.      >    If possible, specify the Swap File on a RAMDISK.  This will
  2055.           speed up the swap considerably.  A ramdisk program is
  2056.           supplied with DOS (RAMDRIVE.SYS or VDISK.SYS) or you can
  2057.           obtain one from a BBS.
  2058.  
  2059.      >    Be sure to specify a complete pathname for the Swap File.
  2060.  
  2061.      >    Do not run any TSR (resident) programs when swapping is in
  2062.           effect.  Doing so may result in a swap error.
  2063.  
  2064.  
  2065.      EXECute Preview Mode
  2066.      --------------------
  2067.  
  2068.      Use the Set Toggles key command, Alt-T, to turn on "EXECute
  2069.      Preview Mode."  This mode is used to test your DOS commands and
  2070.      performs the following steps for each EXECute function:
  2071.  
  2072.      1)   The command will be displayed after expanding variables and
  2073.           converting control characters.
  2074.  
  2075.      2)   You will be given an opportunity to edit and/or cancel the
  2076.           command before it is executed.
  2077.  
  2078.  
  2079.  
  2080.                    {COMMO} (tm)  Macro Programming Guide            39
  2081.  
  2082.  
  2083.  
  2084.      3)   Following execution {COMMO} will wait before restoring the
  2085.           Terminal Screen.  This lets you see any error messages that
  2086.           the command may have displayed.
  2087.  
  2088.      ____
  2089.  
  2090.      EXIT
  2091.      ____
  2092.  
  2093.      Default key:   Alt-X
  2094.      Description:   Exit {COMMO}.
  2095.  
  2096.      General form:
  2097.  
  2098.           {EXIT number}
  2099.  
  2100.                number    The return code to be passed to DOS.  It may
  2101.                          be tested with the IF ERRORLEVEL batch
  2102.                          command.  Range is 0 to 255.
  2103.  
  2104.      Switches:
  2105.  
  2106.                D1 or D   Drop DTR and RTS.  Dropping DTR will cause
  2107.                          the modem to disconnect if it has been
  2108.                          properly initialized.  See Appendix A in the
  2109.                          User Guide and Reference.
  2110.  
  2111.                D0        Do not drop DTR and RTS.
  2112.  
  2113.                          If the switch is absent, the current setting
  2114.                          of the toggle will be used.  The toggle can
  2115.                          be set in the Setup File or by using the
  2116.                          Alt-T key command.
  2117.  
  2118.      Examples:
  2119.  
  2120.           {exit}              No arguments (return code = 0).
  2121.           {exit 3}            With return code.
  2122.           {exit-D}            Drop DTR and RTS.
  2123.  
  2124.      _________
  2125.  
  2126.      GETString
  2127.      _________
  2128.  
  2129.      Default key:   none
  2130.      Description:   Input a string from the modem to a variable.
  2131.  
  2132.      General form:
  2133.  
  2134.           {GETString name,count,label}
  2135.  
  2136.  
  2137.  
  2138.                    {COMMO} (tm)  Macro Programming Guide            40
  2139.  
  2140.  
  2141.  
  2142.                name      The name of the variable to which the string
  2143.                          will be assigned.
  2144.  
  2145.                count     The maximum number of data characters
  2146.                          allowed.  A carriage return will always
  2147.                          terminate input.  May be 1 to 240.  Default
  2148.                          is 240.
  2149.  
  2150.                label     A macro to GOTO if a carriage return is
  2151.                          received and no characters have been entered
  2152.                          (the string will be assigned as null).  If
  2153.                          this argument is omitted, control will pass
  2154.                          to the next function.
  2155.  
  2156.      Switches:
  2157.  
  2158.                A1 or A   "Append" mode.  Characters will be appended
  2159.                          to the variable.  If the current length of
  2160.                          the variable is greater than the count in the
  2161.                          second argument, a count of 240 will be
  2162.                          assumed.
  2163.  
  2164.                A0        The variable will be replaced (default).
  2165.  
  2166.                H1 or H   "Hotkey" mode.  When the maximum number of
  2167.                          characters has been entered, control will
  2168.                          pass to the next function.
  2169.  
  2170.                H0        Ignore all input after the maximum has been
  2171.                          entered, except backspace and carriage return
  2172.                          (default).
  2173.  
  2174.                P1 or P   "Password" mode.  Asterisks will be echoed to
  2175.                          the remote and local terminals in place of
  2176.                          the received characters (Echo Status will be
  2177.                          honored, see SETGet).
  2178.  
  2179.                P0        Characters are echoed as received (default).
  2180.  
  2181.      Examples:
  2182.  
  2183.           {setget 60,timeout,y,^m^j}         Set GETString parameters.
  2184.           {gets fonum,12,badinput}           Get input to "fonum."
  2185.  
  2186.           {gets-p pword,20}                  Get a password.
  2187.  
  2188.  
  2189.      TIPS on using GETString:
  2190.  
  2191.      >    The only control characters allowed (below ASCII 28) are
  2192.           carriage return (ASCII 13) and backspace (ASCII 8).  Other
  2193.  
  2194.  
  2195.  
  2196.                    {COMMO} (tm)  Macro Programming Guide            41
  2197.  
  2198.  
  2199.           control characters should be entered as ^J for linefeed,
  2200.           etc.  See Appendix D in the User Guide and Reference.
  2201.  
  2202.      >    Destructive backspace processing is supported for editing
  2203.           purposes.
  2204.  
  2205.      >    GETString supports "tandem" input.  Characters entered at
  2206.           either end will be input to the string (and displayed at
  2207.           both ends if echo is on (see SETGet).  Turn on Local Echo to
  2208.           see text locally that is sent to the remote with SEND,
  2209.           ASCIiup, etc.
  2210.  
  2211.      >    Use the "H" switch and a character count of 1 for "hotkeys."
  2212.  
  2213.      >    Turn off echo in the SETGet while waiting for the modem to
  2214.           answer (in host mode).  Some modems react poorly to
  2215.           characters being echoed when they are generating a response
  2216.           (such as "RING").
  2217.  
  2218.      >    Incoming characters displayed during a GETString function
  2219.           are not seen by subsequent SSLOok/CALOok/GOLOok/LOOKfor
  2220.           functions.
  2221.  
  2222.      See also SETGet.
  2223.  
  2224.      ______
  2225.  
  2226.      GOLOok
  2227.      ______
  2228.  
  2229.      Default key:   none
  2230.      Description:   Set up an additional string to look for during a
  2231.                     subsequent LOOKfor function.
  2232.  
  2233.      General form:
  2234.  
  2235.           {GOLOok label,target}
  2236.  
  2237.                label     A label to GOTO when the target is received
  2238.                          from the serial port.
  2239.  
  2240.                target    The ASCII string to look for.  The string
  2241.                          begins following the "," and is terminated by
  2242.                          the "}".
  2243.  
  2244.      GOLOok is used in conjunction with LOOKfor.  When the target
  2245.      string appears, control will pass to the label.
  2246.  
  2247.      See LOOKfor for details, examples and tips on using GOLOok.
  2248.  
  2249.      See also: SSLOok, CALOok, SETLook.
  2250.  
  2251.  
  2252.  
  2253.                    {COMMO} (tm)  Macro Programming Guide            42
  2254.  
  2255.  
  2256.      ____
  2257.  
  2258.      GOTO
  2259.      ____
  2260.  
  2261.      Default key:   none
  2262.      Description:   Transfer control to a macro label.
  2263.  
  2264.      Example:
  2265.  
  2266.           {goto mail_run}          Control transferred to label
  2267.                                    "mail_run".
  2268.  
  2269.      ______
  2270.  
  2271.      HANGup
  2272.      ______
  2273.  
  2274.      Default key:   Alt-H
  2275.      Description:   Disconnect by dropping DTR.
  2276.  
  2277.      Examples:
  2278.  
  2279.           {hangup}            Prompt user for disconnect.
  2280.           {hangup y}          Disconnect without prompting.
  2281.  
  2282.      ____
  2283.  
  2284.      HELP
  2285.      ____
  2286.  
  2287.      Default key:   F1
  2288.      Description:   Open Online Help window.
  2289.  
  2290.      Example:
  2291.  
  2292.           {help}              Display key command help
  2293.           {help x}            Display topic "TX"
  2294.  
  2295.      Any single character may be specified.  {COMMO} will prefix it
  2296.      with a "T" and search for the topic code.  You may create your
  2297.      own Online Help file.  See "Modifying the Help File" in the User
  2298.      Guide and Reference.
  2299.  
  2300.      _____
  2301.  
  2302.      HFLOw
  2303.      _____
  2304.  
  2305.      Default key:   none
  2306.      Description:   Set Hardware Flow Control toggle.
  2307.  
  2308.  
  2309.  
  2310.                    {COMMO} (tm)  Macro Programming Guide            43
  2311.  
  2312.  
  2313.      Examples:
  2314.  
  2315.           {hflow}             Toggle Hardware Flow Control on/off.
  2316.           {hflow y}           Turn on Hardware Flow Control.
  2317.           {hflow n}           Turn off Hardware Flow Control.
  2318.  
  2319.      ____
  2320.  
  2321.      HOLD
  2322.      ____
  2323.  
  2324.      Default key:   none
  2325.      Description:   Hold until specified time of day (24 hour format).
  2326.  
  2327.      Examples:
  2328.  
  2329.           {hold 3:30}         Hold until 3:30 am.
  2330.           {hold 16:10}        Hold until 4:10 pm.
  2331.           {hold 0:00}         Hold until midnight.
  2332.  
  2333.      NOTE:  Incoming characters displayed during a HOLD function are
  2334.      not seen by subsequent SSLOok/CALOok/GOLOok/LOOKfor functions.
  2335.  
  2336.      _________
  2337.  
  2338.      IFCArrier
  2339.      _________
  2340.  
  2341.      Default key:   none
  2342.      Description:   Test for presence of carrier detect signal.
  2343.  
  2344.      General form:
  2345.  
  2346.           {IFCArrier true,false}
  2347.  
  2348.                true           A label to GOTO if carrier is detected.
  2349.  
  2350.                false          A label to GOTO if carrier is not
  2351.                               detected.
  2352.  
  2353.      NOTE:  The default when either label is omitted is to pass
  2354.      control to the next function.
  2355.  
  2356.      Example:
  2357.  
  2358.                {ifcarrier c10,c20}
  2359.  
  2360.      Tip on using IFCArrier:
  2361.  
  2362.      >    When using a loop to wait for a change in carrier detect,
  2363.           you should include a short pause in the loop if you want
  2364.           characters to display.  The following sequence will display
  2365.  
  2366.  
  2367.  
  2368.                    {COMMO} (tm)  Macro Programming Guide            44
  2369.  
  2370.  
  2371.           incoming characters while waiting for carrier detect to
  2372.           drop:
  2373.  
  2374.                ... {:cd1} {pause 1} {ifcarrier cd1} ...
  2375.  
  2376.      ___________
  2377.  
  2378.      IFCOndition
  2379.      ___________
  2380.  
  2381.      Default key:   none
  2382.      Description:   Test for conditions set by other functions.
  2383.  
  2384.      General form:
  2385.  
  2386.           {IFCOndition true,false}
  2387.  
  2388.                true      A label to GOTO if the Condition Flag is
  2389.                          true.
  2390.  
  2391.                false     A label to GOTO if the Condition Flag is
  2392.                          false.
  2393.  
  2394.      NOTE:  The default when either label is omitted is to pass
  2395.      control to the next function.
  2396.  
  2397.      Switches:
  2398.  
  2399.                none      Test the current state of the Condition Flag.
  2400.  
  2401.                E1 or E   Test for numeric equality.  A numeric string
  2402.                          contains only the digits 0-9 and is in the
  2403.                          range 0 to 65535.
  2404.  
  2405.                L1 or L   Numeric test -- if first COMPare argument is
  2406.                          less than the second.
  2407.  
  2408.                G1 or G   Numeric test -- if first COMPare argument is
  2409.                          greater than the second.
  2410.  
  2411.      Examples:
  2412.  
  2413.           {compare var1,message}        Compare and set Condition
  2414.           {ifcondit match,nomatch}      Flag.  GOTO "match" if the
  2415.                                         variable "var1" is set to
  2416.                                         "message," to "nomatch" if it
  2417.                                         is not.
  2418.  
  2419.           {compare value,200}           Compare and set conditions.
  2420.           {ifcon-GE toobig,aok}         GOTO "toobig" if "value" is
  2421.                                         greater than or equal to 200,
  2422.                                         else GOTO "aok."
  2423.  
  2424.  
  2425.  
  2426.                    {COMMO} (tm)  Macro Programming Guide            45
  2427.  
  2428.  
  2429.  
  2430.           {instring zipcode,90}         Test if "zipcode" contains
  2431.           {ifcon yes,no}                the digits "90".  If "true"
  2432.                                         GOTO "yes", if "false" GOTO
  2433.                                         "no".
  2434.  
  2435.      Switches may be used in any combination.  If any numeric switches
  2436.      are present, the Condition Flag is not tested.
  2437.  
  2438.      The difference between testing for string equality and numeric
  2439.      equality is shown in this example:
  2440.  
  2441.           The strings "05" and "5" are different text strings, but are
  2442.           numerically equal.
  2443.  
  2444.      ____________
  2445.  
  2446.      IFERrorlevel
  2447.      ____________
  2448.  
  2449.      Default key:   none
  2450.      Description:   Test the Exit Code set by certain functions.
  2451.  
  2452.      General form:
  2453.  
  2454.           {IFERrorlevel number,true,false}
  2455.  
  2456.                number         A number from 0 to 255.  It will be
  2457.                               compared to the last Exit Code that was
  2458.                               set.
  2459.  
  2460.                true           A label to GOTO if the Exit Code is
  2461.                               greater than or equal to "number."
  2462.  
  2463.                false          A label to GOTO if the Exit Code is less
  2464.                               than "number."
  2465.  
  2466.      NOTE:  The default when either label is omitted is to pass
  2467.      control to the next function.
  2468.  
  2469.      Example:
  2470.  
  2471.                {iferror 1,abc,def}      GOTO "abc" if Exit Code is
  2472.                                         greater than or equal to 1. 
  2473.                                         Else GOTO def.
  2474.  
  2475.      TIPS on using IFERrorlevel:
  2476.  
  2477.      >    The Exit Code is set by certain functions (e.g., EXECute-D,
  2478.           SHELl, RXMOdem, SXMOdem) and should normally be tested
  2479.           immediately following execution of those functions.
  2480.  
  2481.  
  2482.  
  2483.                    {COMMO} (tm)  Macro Programming Guide            46
  2484.  
  2485.  
  2486.      >    EXECute without the "D" switch or Shell to DOS will normally
  2487.           set the Exit Code to 0.
  2488.  
  2489.      >    Many programs return an Exit Code greater than 0 when the
  2490.           result is unsuccessful.  DSZ, for example, will return an
  2491.           Exit Code of 1 if the file transfer has failed.
  2492.  
  2493.      >    The value of the Exit Code is also stored in the string
  2494.           variable "_err" and may be tested with COMPare.
  2495.  
  2496.      _______
  2497.  
  2498.      IFEXist
  2499.      _______
  2500.  
  2501.      Default key:   none
  2502.      Description:   Test for existence of a disk file or files.
  2503.  
  2504.      General form:
  2505.  
  2506.           {IFEXist pathname,true,false}
  2507.  
  2508.                pathname       A DOS pathname.  If the path is omitted,
  2509.                               the current directory will be used.  If
  2510.                               wildcards are used the "true" condition
  2511.                               will hold if any files match the
  2512.                               specification.
  2513.  
  2514.                true           A label to GOTO if the file exists.
  2515.  
  2516.                false          A label to GOTO if no files match.
  2517.  
  2518.      NOTE:  The default when either label is omitted is to pass
  2519.      control to the next function.
  2520.  
  2521.      Examples:
  2522.  
  2523.           {ifex a:file.xyz,,m20}             GOTO "m20" if not found.
  2524.           {ifex c:\data\words.txt,345}       GOTO "345" if found.
  2525.           {ifex c:\ul\*.rep,a01,a02}         Using a wildcard.
  2526.  
  2527.      _________
  2528.  
  2529.      INCRement
  2530.      _________
  2531.  
  2532.      Default key:   none
  2533.      Description:   Add a number to a numeric variable.
  2534.  
  2535.      Examples:
  2536.  
  2537.           {incr count}             Add 1 to the variable "count".
  2538.  
  2539.  
  2540.  
  2541.                    {COMMO} (tm)  Macro Programming Guide            47
  2542.  
  2543.  
  2544.           {incr oranges,1234}      Add 1234 to "oranges".
  2545.  
  2546.      Numeric variables and the numbers to be added may range from 0 to
  2547.      65535.  The default number is 1.
  2548.  
  2549.      If the result is greater than 65535 or if either argument is out
  2550.      of range, then the variable will be set to the string "ERROR".
  2551.  
  2552.      If the variable is not numeric, the results will be
  2553.      unpredictable.
  2554.  
  2555.      See also DECRement.
  2556.  
  2557.      _________
  2558.  
  2559.      INITmodem
  2560.      _________
  2561.  
  2562.      Default key:   Alt-O
  2563.      Description:   Send Modem Initialization String.
  2564.  
  2565.      Example:
  2566.  
  2567.           {init}              No arguments
  2568.  
  2569.      _____
  2570.  
  2571.      INPUt
  2572.      _____
  2573.  
  2574.      Default key:   none
  2575.      Description:   Input a string from the keyboard.
  2576.  
  2577.      General form:
  2578.  
  2579.           {INPUt name,prompt}
  2580.  
  2581.                name      The name of a string variable.  The current
  2582.                          value of this variable will appear in the
  2583.                          input line.
  2584.  
  2585.                prompt    A prompt string that will appear in the input
  2586.                          window border.
  2587.  
  2588.      Example:
  2589.  
  2590.           {input upfile,Enter a filename:}        Input a string to
  2591.                                                   the variable
  2592.                                                   "upfile."
  2593.  
  2594.      If 0 data characters are entered, the variable will be set to
  2595.      null.
  2596.  
  2597.  
  2598.  
  2599.                    {COMMO} (tm)  Macro Programming Guide            48
  2600.  
  2601.  
  2602.  
  2603.      NOTE:  If Esc is pressed, macro processing will be terminated
  2604.      unless an exit label has been defined with SETEsc.
  2605.  
  2606.      ________
  2607.  
  2608.      INSTring
  2609.      ________
  2610.  
  2611.      Default key:   none
  2612.      Description:   Find a string within a string, return its
  2613.                     position.
  2614.  
  2615.      General form:
  2616.  
  2617.           {INSTring name,string}
  2618.  
  2619.                name      The name of a variable (string to search in).
  2620.                string    The string to search for.
  2621.  
  2622.      Example:
  2623.  
  2624.           {inst line,abc}     The variable "line" is searched for the
  2625.                               string "abc".
  2626.  
  2627.      INSTring will set the following:
  2628.  
  2629.           1)   The Condition Flag will be set to "true" if the string
  2630.                is found, to "false" if the string is not found.  Test
  2631.                with IFCOndition, no switches.
  2632.  
  2633.           2)   The starting position of the string will be returned in
  2634.                the built-in variable "_pos" (first character is "1"). 
  2635.                "_pos" will be set to zero if the string is not found.
  2636.  
  2637.      ________
  2638.  
  2639.      KEYStuff
  2640.      ________
  2641.  
  2642.      Default key:   none
  2643.      Description:   Put key codes into the keyboard buffer.
  2644.  
  2645.      Examples:
  2646.  
  2647.           {keys 1c0d}         Put a carriage return into the keyboard
  2648.                               buffer.
  2649.  
  2650.           {keys 1e41,6c00}    Put an "A" in the keyboard buffer
  2651.                               followed by Alt-F5.
  2652.  
  2653.  
  2654.  
  2655.                    {COMMO} (tm)  Macro Programming Guide            49
  2656.  
  2657.  
  2658.      This function is usually used prior to EXECuting programs, batch
  2659.      files or DOS commands that require keys to be pressed.  It allows
  2660.      complete automation without operator intervention.
  2661.  
  2662.      TIPS on using KEYStuff:
  2663.  
  2664.      >    The key codes are given in hexadecimal (scan code/character
  2665.           code as received from the BIOS).  Press Alt-K in the
  2666.           Internal Editor to view any key code.
  2667.  
  2668.      >    One or more codes may be listed.  Do not insert extra
  2669.           spaces.
  2670.  
  2671.      >    Usually, when specifying an ASCII character, only the
  2672.           character code need be listed.  Thus the second example
  2673.           above could be written:  {keys 41,6c00}.
  2674.  
  2675.      ______
  2676.  
  2677.      LENGth
  2678.      ______
  2679.  
  2680.      Default key:   none
  2681.      Description:   Determine the length of a string.
  2682.  
  2683.      Examples:
  2684.  
  2685.           {leng %line}             Find the length of the string in
  2686.                                    the variable "line".
  2687.  
  2688.           {leng %line1%%line2}     Find the combined length of "line1"
  2689.                                    and "line2".
  2690.  
  2691.      The length will be returned in the built-in variable "_len".  If
  2692.      the string is null, the length will be set to zero.
  2693.  
  2694.      ______
  2695.  
  2696.      LIGHts
  2697.      ______
  2698.  
  2699.      Default key:   Alt-0
  2700.      Description:   Set Signal Lights toggle.
  2701.  
  2702.      Examples:
  2703.  
  2704.           {lights}            Toggle Signal Lights on/off.
  2705.           {lights y}          Turn on Signal Lights.
  2706.           {lights n}          Turn off Signal Lights.
  2707.  
  2708.  
  2709.  
  2710.                    {COMMO} (tm)  Macro Programming Guide            50
  2711.  
  2712.  
  2713.      _________
  2714.  
  2715.      LOCAlecho
  2716.      _________
  2717.  
  2718.      Default key:   none
  2719.      Description:   Set Local Echo toggle.
  2720.  
  2721.      Examples:
  2722.  
  2723.           {local}             Toggle Local Echo on/off.
  2724.           {local y}           Turn on Local Echo.
  2725.           {local n}           Turn off Local Echo.
  2726.  
  2727.      _______
  2728.  
  2729.      LOOKfor
  2730.      _______
  2731.  
  2732.      Default key:   none
  2733.      Description:   Look for strings in the modem input stream.
  2734.  
  2735.      LOOKfor is used in conjunction with SSLOok, CALOok and GOLOok to
  2736.      scan for as many as 16 strings at the same time.  When SSLOok,
  2737.      CALOok and GOLOok set up additional strings to look for, the
  2738.      actual "looking" does not take place until the LOOKfor executes.
  2739.  
  2740.      Parameters controlling LOOKfor are set with the SETLook function
  2741.      and may be changed at any time with another SETLook.  See the
  2742.      description of the SETLook function for details.
  2743.  
  2744.      Examples using LOOKfor only:
  2745.  
  2746.           {lookfor first name?}    Look for the string "first name?"
  2747.  
  2748.           {look ^(COMMO^)}         Look for the string "{COMMO}".
  2749.  
  2750.           When the string comes in, control will pass to the next
  2751.           function.
  2752.  
  2753.      Example construct using SSLOok/CALOok/GOLOok/LOOKfor:
  2754.  
  2755.                     {setlook 60,hng,3,n|}
  2756.                     {setv ss_r,|}
  2757.                       ...
  2758.           {:start}
  2759.                     {golook label-a,target1}
  2760.                     {calook start,label-b,target2}
  2761.                     {sslook ss_r,target3}
  2762.                     {golook ,target4}
  2763.                     {lookfor target5} {send answer5} {goto label-c}
  2764.  
  2765.  
  2766.  
  2767.                    {COMMO} (tm)  Macro Programming Guide            51
  2768.  
  2769.  
  2770.           {:label-a}     {hangup y} {goto cancel}
  2771.           {:label-b}     {send answer2} {call subr} {return}
  2772.           {:label-c}          ...
  2773.  
  2774.           In this example {COMMO} will look for five target strings.
  2775.  
  2776.           When a target specified in any of the CALOok, GOLOok or
  2777.           LOOKfor functions is received, the LOOKfor is cancelled.  It
  2778.           may be set up again by going to "start".
  2779.  
  2780.           When the target specified in the SSLOok is received, the
  2781.           string in the variable will be transmitted to the serial
  2782.           port.  The LOOKfor will continue to look for the same
  2783.           targets.
  2784.  
  2785.           The GOLOok function for target1 will GOTO "label-a" when the
  2786.           string comes in.  In the example control will pass to
  2787.           "cancel" (macro not shown).
  2788.  
  2789.           If target2 comes in, the CALOok function will set "start" as
  2790.           the return point and then CALL "label-b".  When this routine
  2791.           RETUrns, control returns to "start" and the five string
  2792.           LOOKfor will be set up again.
  2793.  
  2794.           If target3 is received, the string in the variable "ss_r"
  2795.           will be sent (in this case, a carriage return) and looking
  2796.           will continue.
  2797.  
  2798.           The GOLOok for target4 has a null label and control will
  2799.           pass to the function following the LOOKfor if that string
  2800.           comes in.  The "," must be present.
  2801.  
  2802.           If target5 comes in, control will pass to the function
  2803.           following the LOOKfor.
  2804.  
  2805.      TIPS on creating LOOKfor strings:
  2806.  
  2807.      >    There should be just one space following the LOOKfor
  2808.           function name.  Any spaces beyond this point are part of the
  2809.           string.  The string ends at the right curly brace.
  2810.  
  2811.      >    SSLOok/CALOok/GOLOok/Auto Receive strings begin immediately
  2812.           after the comma.  There should be no spaces unless they are
  2813.           part of the string.
  2814.  
  2815.      >    Strings may be up to 32 characters in length (control
  2816.           characters like "^M" count as one).  Upper/lower case is
  2817.           ignored.
  2818.  
  2819.      >    ANSI control sequences are filtered if ANSI or VT102
  2820.           emulation is enabled.
  2821.  
  2822.  
  2823.  
  2824.                    {COMMO} (tm)  Macro Programming Guide            52
  2825.  
  2826.  
  2827.      >    Remember that short strings may not be unique enough, long
  2828.           strings may not match due to line noise.
  2829.  
  2830.      >    Rules for representing special characters in
  2831.           SSLOok/CALOok/GOLOok/LOOKfor/Auto Receive strings are given
  2832.           in Appendix D in the User Guide and Reference.
  2833.  
  2834.      Additional TIPS:
  2835.  
  2836.      >    SSLOok, CALOok and GOLOok functions should immediately
  2837.           precede a LOOKfor (no string compares actually occur until
  2838.           the LOOKfor executes).  Up to 15 SSLOok/CALOok/GOLOok
  2839.           strings may be used in addition to the LOOKfor (up to 16
  2840.           strings total).
  2841.  
  2842.      >    FILTER Capture Mode should be used to determine the exact
  2843.           prompt to look for.  The LOOKfor sees the incoming data
  2844.           exactly as it is captured when FILTER mode is set.
  2845.  
  2846.      >    If two or more strings cause a match at the same time, the
  2847.           LAST such string listed is the one acted upon (for example,
  2848.           if "abcdef" and "def" are listed and the string "abcdef"
  2849.           comes in).
  2850.  
  2851.      See also: SSLOok, CALOok, GOLOok, SETLook.
  2852.  
  2853.      _______
  2854.  
  2855.      MACLoad
  2856.      _______
  2857.  
  2858.      Default key:   none
  2859.      Description:   Load a new Macro File.
  2860.  
  2861.      Switches:
  2862.  
  2863.                R1 or R   Specifies that COMMO.MAC will be reloaded
  2864.                          when carrier detect is lost.  Normally this
  2865.                          would occur at the end of the call.
  2866.  
  2867.                R0        Do not reload COMMO.MAC when carrier is lost
  2868.                          (default).
  2869.  
  2870.      General form:
  2871.  
  2872.           {MACLoad filename,label}
  2873.  
  2874.                filename       The new Macro File.  Do NOT specify a
  2875.                               path; the {COMMO} home directory will be
  2876.                               used.
  2877.  
  2878.  
  2879.  
  2880.                    {COMMO} (tm)  Macro Programming Guide            53
  2881.  
  2882.  
  2883.                label          A label to GOTO when the new file is
  2884.                               loaded.  Optional.
  2885.  
  2886.      Examples:
  2887.  
  2888.           {macload-R vt102-1.mac}       Load vt102-1.mac, reload
  2889.                                         COMMO.MAC at the end of the
  2890.                                         call.
  2891.  
  2892.           {macl newmac.fil,abc}         Load newmac.fil, start macro
  2893.                                         "abc" in the new file.
  2894.  
  2895.  
  2896.      IMPORTANT!  The new Macro File must reside in the {COMMO} home
  2897.      directory (do not specify a path).
  2898.  
  2899.      The current file will be saved to disk if changes are
  2900.      outstanding.  The new file is then loaded in place of the current
  2901.      one (all macros are replaced).  
  2902.  
  2903.      MACLoad should be the last function in a macro, since control is
  2904.      not returned.
  2905.  
  2906.      _____
  2907.  
  2908.      MACRo
  2909.      _____
  2910.  
  2911.      Default key:   Alt-M
  2912.      Description:   Open Macro Processor window.
  2913.  
  2914.      Examples:
  2915.  
  2916.           {macro}             Open window at current position.
  2917.           {macro menu1}       Open window at "menu1."
  2918.  
  2919.      NOTE:  The MACRo function always terminates the macro that is
  2920.      currently executing.
  2921.  
  2922.      A string argument may be included to facilitate the creation of
  2923.      menus within the Macro File.  The first occurrence of the
  2924.      argument string will become the top line of the display when the
  2925.      window is opened.
  2926.  
  2927.      The Selector Bar will be positioned on the first screen line that
  2928.      has a left curly brace, if any.
  2929.  
  2930.  
  2931.  
  2932.                    {COMMO} (tm)  Macro Programming Guide            54
  2933.  
  2934.  
  2935.      Here is an example of how to structure a menu using MACRo:
  2936.  
  2937.                                         | (this is past col. 80)
  2938.                                         | menu111
  2939.                Name of Menu             |
  2940.                                         |
  2941.                                         |
  2942.                Selection 1              | {goto sel1}
  2943.                Selection 2              | {goto sel2}
  2944.                Selection 3              | {goto sel3}
  2945.  
  2946.           {:af1} {macro menu111}
  2947.           {:sel1} ...
  2948.           {:sel2} ...
  2949.           {:sel3} ...
  2950.  
  2951.      The upper line with "menu111" will be the top line of the screen. 
  2952.      Pressing Alt-F1 will bring up the menu with the Selector Bar on
  2953.      Selection 1.  Macros at "sel1", "sel2" and "sel3" will process
  2954.      the respective selections.
  2955.  
  2956.      Note that the macro at "af1" to invoke the menu must be below the
  2957.      menu since it contains the string and would be found in the
  2958.      search.
  2959.  
  2960.      See also MENU.
  2961.  
  2962.      ____
  2963.  
  2964.      MARK
  2965.      ____
  2966.  
  2967.      Default key:   none
  2968.      Description:   Mark Dialing Directory entries for dialing.
  2969.  
  2970.      Example:
  2971.  
  2972.           {mark joes-bbs,file-city}     Mark entries for dialing.
  2973.  
  2974.      Dialing Strings may be separated by spaces or commas.
  2975.  
  2976.      {COMMO} will search the Dialing Directory for each string and
  2977.      mark the first entry where a match is found.  Case is ignored.
  2978.  
  2979.      The strings may consist of any part of a Dialing Directory entry
  2980.      line (including strings contained within curly braces), but must
  2981.      NOT contain any spaces, commas or curly braces.
  2982.  
  2983.      See also: DIAL, UNMArk.
  2984.  
  2985.  
  2986.  
  2987.                    {COMMO} (tm)  Macro Programming Guide            55
  2988.  
  2989.  
  2990.      ____
  2991.  
  2992.      MENU
  2993.      ____
  2994.  
  2995.      Default key:   none
  2996.      Description:   Create a pop-up macro menu.
  2997.  
  2998.      General form:
  2999.  
  3000.           {SETV _menu1,text1}
  3001.           {SETV _menu2,text2}
  3002.                ...
  3003.           {SETV _menuN,textN}
  3004.  
  3005.                text1          Text to be placed on first information
  3006.                               line in the pop-up window (third line
  3007.                               down, counting from the top border).
  3008.  
  3009.                               NOTE:  These text strings are simply
  3010.                               information and have no effect on which
  3011.                               macros will be executed.
  3012.  
  3013.                text2          Text to be placed on second information
  3014.                               line.
  3015.                ...            ...
  3016.  
  3017.                textN          Text to be placed on Nth information
  3018.                               line.
  3019.  
  3020.           {SETV _mlabel,label1,label2,...}
  3021.  
  3022.                label1         Label to GOTO if F1, A or 1 is pressed. 
  3023.                               Any of the three keys will activate the
  3024.                               macro at the first label.
  3025.  
  3026.                label2         Label to GOTO if F2, B or 2 is pressed.
  3027.  
  3028.                               NOTE:  Labels are positional and may be
  3029.                               omitted using null arguments for keys
  3030.                               that aren't used.  See example 2 below.
  3031.                ...            ...
  3032.  
  3033.           {SETV _mcolor,text,border}
  3034.  
  3035.                text           Colors for the text area of the pop-up
  3036.                               window.
  3037.  
  3038.                               NOTE:  The attributes are specified in
  3039.                               the same manner as the colors in the
  3040.                               Setup File (press F7 in the Internal
  3041.                               Editor to display the Color Chart).  
  3042.  
  3043.  
  3044.  
  3045.                    {COMMO} (tm)  Macro Programming Guide            56
  3046.  
  3047.  
  3048.  
  3049.                border         Colors for the window border.
  3050.  
  3051.           {MENU height,width,string}
  3052.  
  3053.                height         Total number of rows from top to bottom
  3054.                               of pop-up window, including borders. 
  3055.                               Minimum is 5.
  3056.  
  3057.                width          Total number of columns from left side
  3058.                               to right side, including borders. 
  3059.                               Minimum is 23.
  3060.  
  3061.                string         Title string that will appear in the top
  3062.                               border.
  3063.  
  3064.      Example 1:
  3065.  
  3066.                {setv _menu1, F1  Call computer at work}
  3067.                {setv _menu3, F2  Call E-mail service}
  3068.                {setv _menu5, F3  Run offline mail reader}
  3069.                {setv _mlabel,work,mail,reader}
  3070.                {setv _mcolor,17,30}
  3071.                {menu 9,32,Daily Activity Menu} {}
  3072.  
  3073.           {:work}   ... macro to call work computer.
  3074.           {:mail}   ... macro to call E-mail service.
  3075.           {:reader} ... macro to run offline reader.
  3076.  
  3077.           This menu specifies that function keys be pressed to
  3078.           activate the macros.  You could also press A or 1 instead of
  3079.           F1, B or 2 instead of F2, etc.  The macros may be as simple
  3080.           or as complex as desired to complete the task.
  3081.  
  3082.      Example 2:
  3083.  
  3084.                {setv _menu1, D - Dialing Directory}
  3085.                {setv _menu2, M - Macro File}
  3086.                {setv _menu3, S - Shell to DOS (with swap)}
  3087.                {setv _menu4, E - Edit a file}
  3088.                {setv _mlabel,,,,ddir,edit,,,,,,,,mfile,,,,,,dos}
  3089.                {setv _mcolor,03,47}
  3090.                {menu 8,33,Common Commands} {}
  3091.  
  3092.           {:ddir}   {dial} {}
  3093.           {:edit}   {input efile,Filename to Edit} {edit %efile} {}
  3094.           {:mfile}  {macro}
  3095.           {:dos}    {shell-s} {}
  3096.  
  3097.           This menu uses "mnemonic" key labeling -- D for (D)ialing
  3098.           Directory, etc.  Notice that there are three empty positions
  3099.           in the "_mlabel" list prior to "ddir" and "edit".  These
  3100.  
  3101.  
  3102.  
  3103.                    {COMMO} (tm)  Macro Programming Guide            57
  3104.  
  3105.  
  3106.           correspond to A, B and C, which are not used in this menu. 
  3107.           Then there are empty positions up to M and then up to S.
  3108.  
  3109.      TIPS on using MENU:
  3110.  
  3111.      >    The dimensions of the window are limited by the current size
  3112.           of the Terminal Screen.
  3113.  
  3114.      >    The total number of displayable lines is "height" less 4. 
  3115.           Lines in the window for which no "_menux" variable has been
  3116.           defined will be left blank.
  3117.  
  3118.      >    Up to 26 labels can be specified in each menu.  These
  3119.           correspond to pressing the letters A through Z.  The first
  3120.           12 labels also correspond to pressing F1 through F12, while
  3121.           the first 9 labels correspond to pressing 1 through 9.
  3122.  
  3123.      >    All variables used to create the menu are automatically
  3124.           deleted from Variable Space after the menu is displayed. 
  3125.  
  3126.      >    The last colors used to display a menu will persist until
  3127.           they are changed by setting the "_mcolor" variable.
  3128.  
  3129.      >    If Esc is pressed to exit the menu, macro processing
  3130.           continues in sequence following the MENU function.
  3131.  
  3132.      See also MACRo.
  3133.  
  3134.      ________
  3135.  
  3136.      MULTiply
  3137.      ________
  3138.  
  3139.      Default key:   none
  3140.      Description:   Multiply a numeric variable by a number.
  3141.  
  3142.      Example:
  3143.  
  3144.           {mult money,10}          Multiply "money" by 10.
  3145.  
  3146.      Numeric variables and the multipliers may range from 0 to 65535. 
  3147.      The default multiplier is 1.
  3148.  
  3149.      If the result is greater than 65535 or if either argument is out
  3150.      of range, then the variable will be set to the string "ERROR".
  3151.  
  3152.      If the variable is not numeric, the results will be
  3153.      unpredictable.
  3154.  
  3155.  
  3156.  
  3157.                    {COMMO} (tm)  Macro Programming Guide            58
  3158.  
  3159.  
  3160.      _________
  3161.  
  3162.      NOCArrier
  3163.      _________
  3164.  
  3165.      Default key:   none
  3166.      Description:   Sets/resets a macro to execute when carrier detect
  3167.                     is lost.
  3168.  
  3169.      Examples:
  3170.  
  3171.           {nocar carrlost}         GOTO the label "carrlost" when the
  3172.                                    carrier detect signal drops.
  3173.  
  3174.           {nocar}                  Turn off the carrier lost label.
  3175.  
  3176.      IMPORTANT:  This feature is enabled only when a connection is
  3177.      made using {COMMO}'s Auto Dialer.  Also, if carrier drops while a
  3178.      macro is running or a command window is open (such as the Dialing
  3179.      Directory or Capture File Options), the carrier lost macro will
  3180.      not activate.
  3181.  
  3182.      Be sure that you have your modem configured to provide the
  3183.      carrier detect signal.  See Appendix A in the User Guide and
  3184.      Reference for modem information.
  3185.  
  3186.      ____
  3187.  
  3188.      NOOP
  3189.      ____
  3190.  
  3191.      Default key:   none
  3192.      Description:   No-op function, does nothing
  3193.  
  3194.      Example:
  3195.  
  3196.           {noop}              No arguments.
  3197.  
  3198.      ______
  3199.  
  3200.      OFFLog
  3201.      ______
  3202.  
  3203.      Default key:   none
  3204.      Description:   Make an {Off} entry in the Usage Log.
  3205.  
  3206.      Example:
  3207.  
  3208.           {offlog}            No arguments.
  3209.  
  3210.      This function is useful on systems that do not support the
  3211.      carrier detect signal.
  3212.  
  3213.  
  3214.  
  3215.                    {COMMO} (tm)  Macro Programming Guide            59
  3216.  
  3217.  
  3218.  
  3219.      _____
  3220.  
  3221.      PARMs
  3222.      _____
  3223.  
  3224.      Default key:   Alt-P
  3225.      Description:   Set Current Terminal Parameters
  3226.  
  3227.      General form:
  3228.  
  3229.           {PARMs speed,format,comport,terminal-type,delay}
  3230.  
  3231.                speed          The bps rate: 2400, 9600, etc.
  3232.                format         The data format: 8n1, 7e1, etc.
  3233.                comport        The serial port number: 1, 2, 3 or 4.
  3234.                terminal       The terminal-type: A, V or T.
  3235.                delay          The inter-character delay factor: 0-999.
  3236.  
  3237.      Examples:
  3238.  
  3239.           {parms 2400,8,1,,20}     Set 2400 bps, 8n1, Com1, delay =
  3240.                                    20.
  3241.  
  3242.           {parms ,,4,V}            Set Com4 VT102.
  3243.  
  3244.           {parms 19200,7o1}        Set 19200 bps, 7o1.
  3245.  
  3246.      IMPORTANT:  Omitted parameters are not changed.
  3247.  
  3248.      See also DPARms.
  3249.  
  3250.      ________
  3251.  
  3252.      PASSword
  3253.      ________
  3254.  
  3255.      Default key:   Alt-W
  3256.      Description:   Send current password.
  3257.  
  3258.      Example:
  3259.  
  3260.           {password}          No arguments.
  3261.  
  3262.      The current password is obtained from the Dialing Directory entry
  3263.      whenever a number is dialed.  If no password is specified no
  3264.      characters will be sent.
  3265.  
  3266.  
  3267.  
  3268.                    {COMMO} (tm)  Macro Programming Guide            60
  3269.  
  3270.  
  3271.      _____
  3272.  
  3273.      PAUSe
  3274.      _____
  3275.  
  3276.      Default key:   none
  3277.      Description:   Pause for up to 999 seconds.
  3278.  
  3279.      Example:
  3280.  
  3281.           {pause 25}          Pause for 25 seconds.
  3282.  
  3283.      NOTE:  Incoming characters displayed during a PAUSe function are
  3284.      not seen by subsequent CALOok/GOLOok/LOOKfor functions.
  3285.  
  3286.      ________
  3287.  
  3288.      POPStack
  3289.      ________
  3290.  
  3291.      Default key:   none
  3292.      Description:   Pop an element from the macro stack.
  3293.  
  3294.      Switches:
  3295.  
  3296.                C1 or C   Clear all elements from the stack.
  3297.  
  3298.                C0        Pop the top element (default).
  3299.  
  3300.      Examples:
  3301.  
  3302.           {pops}              Pop the top element.
  3303.           {pops-c}            Clear the stack.
  3304.  
  3305.      POPStack throws away the top element on the macro stack.  This
  3306.      element would have been used by the next RETUrn function.
  3307.  
  3308.      See PUSHstack for a more complete description of the use of this
  3309.      function.
  3310.  
  3311.      See also CALL, RETUrn.
  3312.  
  3313.      ________
  3314.  
  3315.      PRINtlog
  3316.      ________
  3317.  
  3318.      Default key:   Alt-2
  3319.      Description:   Set Print Log toggle.
  3320.  
  3321.      Examples:
  3322.  
  3323.  
  3324.  
  3325.                    {COMMO} (tm)  Macro Programming Guide            61
  3326.  
  3327.  
  3328.           {print}             Toggle Print Log on/off.
  3329.           {print y}           Turn on Print Log.
  3330.           {print n}           Turn off Print Log.
  3331.  
  3332.      _________
  3333.  
  3334.      PUSHstack
  3335.      _________
  3336.  
  3337.      Default key:   none
  3338.      Description:   Push a return point onto the macro stack.
  3339.  
  3340.      Examples:
  3341.  
  3342.           {push}              Push the current location.
  3343.           {push abc}          Push the location "abc".
  3344.  
  3345.      When there are no arguments, the location pushed is the location
  3346.      of the PUSHstack function itself (i.e., it will be executed again
  3347.      when a RETUrn is encountered).
  3348.  
  3349.      Explanation:  Whenever a CALL is executed, the location of the
  3350.      function following the CALL (the "return point") is "pushed" onto
  3351.      the macro stack.  When a subsequent RETUrn is executed, the
  3352.      location at the top of the stack is "popped" and control is
  3353.      transferred to that location.  This allows "nesting" of CALLs and
  3354.      RETUrns.
  3355.  
  3356.      PUSHstack will push a return point onto the macro stack without
  3357.      transferring control to the location (control continues in
  3358.      sequence).  A subsequent RETUrn will transfer control to the
  3359.      location that was pushed.
  3360.  
  3361.      POPStack will remove the top stack element without transferring
  3362.      control to it (control continues in sequence).
  3363.  
  3364.      See also CALL, RETUrn.
  3365.  
  3366.      ______
  3367.  
  3368.      RCLOse
  3369.      ______
  3370.  
  3371.      Default key:   none
  3372.      Description:   Close the read file.
  3373.  
  3374.      Example:
  3375.  
  3376.           {rclose}            No arguments.
  3377.  
  3378.      NOTE:  The read file will be closed automatically in the
  3379.      following situations:
  3380.  
  3381.  
  3382.  
  3383.                    {COMMO} (tm)  Macro Programming Guide            62
  3384.  
  3385.  
  3386.  
  3387.           1)   When an attempt is made to read past the end of the
  3388.                file.
  3389.           2)   When the macro terminates (STOP, EXIT, etc.).
  3390.  
  3391.      See also ROPEn, READ.
  3392.  
  3393.      ____
  3394.  
  3395.      READ
  3396.      ____
  3397.  
  3398.      Default key:   none
  3399.      Description:   Read a line from the read file to a variable.
  3400.  
  3401.      Example:
  3402.  
  3403.           {read nextline}          Read the next line in the file into
  3404.                                    the variable "nextline."
  3405.  
  3406.      TIPS on reading files:
  3407.  
  3408.      >    A file must be open for reading or a macro error will
  3409.           result.  
  3410.  
  3411.      >    Each READ will get the next line in the file (lines are
  3412.           terminated by carriage return and linefeed).
  3413.  
  3414.      >    When an attempt is made to read past the end of file,
  3415.           control will GOTO the label specified in the ROPEn.  If no
  3416.           label was specified or if the label was invalid, control
  3417.           will continue in sequence.  In either case the file is
  3418.           automatically closed and the variable is set to null.
  3419.  
  3420.      >    READ will set the Exit Code to 0 unless the end of file was
  3421.           encountered, in which case it will be set to 1.  The Exit
  3422.           Code is stored in the built-in variable "_err" and can be
  3423.           tested with the IFERrorlevel function.
  3424.  
  3425.      >    ALL control characters (below ASCII 28) will be discarded,
  3426.           including the carriage return/linefeed that terminates the
  3427.           line.
  3428.  
  3429.      >    Lines longer than 240 characters will be truncated to a
  3430.           length of 240.
  3431.  
  3432.      See also ROPEn, RCLOse
  3433.  
  3434.  
  3435.  
  3436.                    {COMMO} (tm)  Macro Programming Guide            63
  3437.  
  3438.  
  3439.      ______
  3440.  
  3441.      RETUrn
  3442.      ______
  3443.  
  3444.      Default key:   none
  3445.      Description:   Return from a CALLed macro.
  3446.  
  3447.      Example:
  3448.  
  3449.           {return}            No arguments.
  3450.  
  3451.      This function will return control to a location determined by the
  3452.      last CALL or PUSHstack function.  See PUSHstack for a more
  3453.      complete description of CALL and RETUrn.
  3454.  
  3455.      NOTE:  If a RETUrn is encountered and no CALL or PUSHstack has
  3456.      been executed, a STOP will occur.  This is useful in macros that
  3457.      are CALLed and are also used standalone (such as protocol file
  3458.      transfer macros).
  3459.  
  3460.      See also CALL, PUSHstack, POPStack.
  3461.  
  3462.      _____
  3463.  
  3464.      ROPEn
  3465.      _____
  3466.  
  3467.      Default key:   none
  3468.      Description:   Open a file for reading.
  3469.  
  3470.      General Form:
  3471.  
  3472.           {ROPEn pathname,label}
  3473.  
  3474.                pathname       The pathname of the file to open.
  3475.  
  3476.                label          A label to GOTO when a READ is attempted
  3477.                               at the end of the file.
  3478.  
  3479.      Example:
  3480.  
  3481.           {ropen c:\bbs\file.txt,nomore}     Open the file and set the
  3482.                                              label "nomore" to GOTO
  3483.                                              when the end of the file
  3484.                                              is reached.
  3485.  
  3486.      TIPS on using ROPEn:
  3487.  
  3488.      >    Only one file may be opened for reading (and one for
  3489.           writing).
  3490.  
  3491.  
  3492.  
  3493.                    {COMMO} (tm)  Macro Programming Guide            64
  3494.  
  3495.  
  3496.      >    The file will be automatically closed when the end of the
  3497.           file is encountered during a READ (whether or not a label is
  3498.           specified).  An RCLOse is not needed in this situation.
  3499.  
  3500.      See also READ, RCLOse.
  3501.  
  3502.      _____
  3503.  
  3504.      RTRAn
  3505.      _____
  3506.  
  3507.      Default key:   none
  3508.      Description:   Maintain Receive Translate Table.
  3509.  
  3510.      Switches:
  3511.  
  3512.                I1 or I   Initialize Receive Translate Table to default
  3513.                          values (consecutive 0 to 255).
  3514.  
  3515.                I0        Do not initialize (default).
  3516.  
  3517.      Examples:
  3518.  
  3519.           {rtran y}                Turn receive translation ON.
  3520.  
  3521.           {rtran-i n}              Initialize the table and turn it
  3522.                                    OFF.
  3523.  
  3524.           {rtran 26,0}             Change ASCII 26 to null (ASCII 0,
  3525.                                    which will not display).
  3526.  
  3527.           {rtran-i y,#8,224,240}   Initialize the table, turn receive
  3528.                                    translation ON, change ASCII 224 to
  3529.                                    240, 225 to 241, ..., 231 to 247. 
  3530.  
  3531.           {rtran}                  Toggle receive translation ON/OFF.
  3532.  
  3533.           {rtran #13,65,78,#13,78,65,#13,97,110,#13,110,97}
  3534.                                    ROT13 translation.  This exchanges
  3535.                                    each letter in the first half of
  3536.                                    the alphabet with the corresponding
  3537.                                    letter from the second half (and
  3538.                                    vice-versa).
  3539.  
  3540.      Rules for RTRAn arguments are the same as for the {rtr=} item in
  3541.      the Setup File.  In addition, "n" may be used as the first
  3542.      argument to turn receive translation OFF at any time.
  3543.  
  3544.      See "Edit Setup File" in the User Guide and Reference for details
  3545.      and more examples.
  3546.  
  3547.      TIPS on using RTRAn:
  3548.  
  3549.  
  3550.  
  3551.                    {COMMO} (tm)  Macro Programming Guide            65
  3552.  
  3553.  
  3554.  
  3555.      >    Some control characters are unaffected by translation when
  3556.           certain features are enabled.  Examples:  XON (17) and XOFF
  3557.           (19) are not translated when Software Flow Control is on. 
  3558.           ENQ (5) is not translated when ENQ/ACK emulation is on.
  3559.  
  3560.      >    When the Capture Mode is set to RAW, data will be captured
  3561.           prior to translation.  FILTER and SCREEN captures will
  3562.           contain translated data.
  3563.  
  3564.      >    LOOKfor will always see translated data.  Use FILTER Capture
  3565.           Mode to see what LOOKfor sees.
  3566.  
  3567.      >    In GETString, incoming data (as well as locally typed
  3568.           characters) will be translated with the Receive Translate
  3569.           Table (it may be necessary to turn receive translation off
  3570.           during certain GETString functions).
  3571.  
  3572.      See also STRAn.
  3573.  
  3574.      _______
  3575.  
  3576.      RXMOdem
  3577.      _______
  3578.  
  3579.      Default key:   none
  3580.      Description:   Receive a file using the Xmodem protocol.
  3581.  
  3582.      Switches:
  3583.  
  3584.                See RYMOdem (switches are the same).
  3585.  
  3586.      Example:
  3587.  
  3588.           {rxmo-ya c:\dl\file.zip}      Receive "file.zip", overwrite
  3589.                                         the file if it exists, sound
  3590.                                         the alarm.
  3591.  
  3592.      Only one file may be received with each RXMOdem function (the
  3593.      file must be explicitly named, but need not be given the same
  3594.      name as on the remote system).
  3595.  
  3596.      See RYMOdem for tips that apply to both RXMOdem and RYMOdem.
  3597.  
  3598.      See also SXMOdem, RYMOdem.
  3599.  
  3600.  
  3601.  
  3602.                    {COMMO} (tm)  Macro Programming Guide            66
  3603.  
  3604.  
  3605.      _______
  3606.  
  3607.      RYMOdem
  3608.      _______
  3609.  
  3610.      Default key:   none
  3611.      Description:   Receive files using the Ymodem Batch protocol.
  3612.  
  3613.      Switches:
  3614.  
  3615.                C1 or C   Use CRC error correction (default).
  3616.                C0        Use Checksum error correction.
  3617.  
  3618.                G1 or G   Use streaming (fast) transfer method.
  3619.                          IMPORTANT:  Use only with error-correcting
  3620.                          modems or direct connections between
  3621.                          computers.
  3622.                G0        Use normal (error-correcting) transfer method
  3623.                          (default).
  3624.  
  3625.                Y1 or Y   Overwrite an existing file when a received
  3626.                          file has the same name (the existing file
  3627.                          will be erased).
  3628.                Y0        Cancel the transfer if a received file has
  3629.                          the same name as an existing file (default).
  3630.  
  3631.                D1 or D   Cancel transfer if carrier detect is lost
  3632.                          (default).
  3633.                D0        Ignore state of carrier detect.
  3634.  
  3635.                A1 or A   Sound the alarm at the end of the transfer.
  3636.                A0        Do not sound the alarm (default).
  3637.  
  3638.                W         Wait for a keypress at end of transfer.
  3639.                Wn        Wait for "n" seconds, "n" may range from 0 to
  3640.                          999.  Press a key to cancel the wait.
  3641.                          Note:  Default (no "W" switch) is no wait.
  3642.  
  3643.      Examples:
  3644.  
  3645.           {rymo-ya %dldir}    Receive files into the download
  3646.                               directory, overwrite a file if it
  3647.                               exists, sound the alarm.
  3648.  
  3649.           {rymo-gw3}          Receive files using the "G" method into
  3650.                               the current directory.  Wait 3 seconds
  3651.                               before returning to the Terminal Screen.
  3652.  
  3653.      Ymodem is a "batch" protocol that will receive multiple files. 
  3654.      Filenames are transmitted by the sender and are used to name
  3655.      files at the receiving end.  A filename "collision" will cause
  3656.      the transfer to cancel unless the "Y" switch is used.  File sizes
  3657.  
  3658.  
  3659.  
  3660.                    {COMMO} (tm)  Macro Programming Guide            67
  3661.  
  3662.  
  3663.      are also transmitted by the sender and are used to truncate the
  3664.      file to the proper size.
  3665.  
  3666.      TIPS on using RYMOdem and RXMOdem:
  3667.  
  3668.      >    The "G" method is specified by the receiver.  Be sure that
  3669.           the sender allows it before starting.
  3670.  
  3671.      >    Block size is established by the sender and may be changed
  3672.           on a block-by-block basis (always 1024 when the "G" method
  3673.           is used).
  3674.  
  3675.      >    Some conditions that will cancel a transfer:
  3676.             1) 10 consecutive errors.
  3677.             2) Any error when "G" method is used.
  3678.             3) The file to be received already exists and the "Y"
  3679.                switch is not present.
  3680.             4) The sender has transmitted CAN (^X) characters.
  3681.  
  3682.      >    The Exit Code (test with IFER) will be set at the end of the
  3683.           transfer.  The Exit Code will also be stored in the variable
  3684.           "_err".  0 means success, 1 means failure.
  3685.  
  3686.      >    If the Usage Log is enabled, an entry will be made after
  3687.           each file is transferred (or if a transfer is cancelled).
  3688.  
  3689.      See also SXMOdem, RYMOdem.
  3690.  
  3691.      ______
  3692.  
  3693.      SCREen
  3694.      ______
  3695.  
  3696.      Default key:   Alt-I
  3697.      Description:   Screen Image Save.
  3698.  
  3699.      Examples:
  3700.  
  3701.           {screen}                 Open Screen Image Save window.
  3702.           {screen y}               Append screen image to current
  3703.                                    file.
  3704.           {screen y,commo.scr}     Append screen image to indicated
  3705.                                    file. (and change current
  3706.                                    pathname).
  3707.           {screen n,c:\file.xyz}   Change current screen image
  3708.                                    pathname (don't save screen to
  3709.                                    file).
  3710.  
  3711.  
  3712.  
  3713.                    {COMMO} (tm)  Macro Programming Guide            68
  3714.  
  3715.  
  3716.      __________
  3717.  
  3718.      SCROllback
  3719.      __________
  3720.  
  3721.      Default key:   Alt-K
  3722.      Description:   Display Scrollback Buffer
  3723.  
  3724.      Example:
  3725.  
  3726.           {scroll}            No arguments.
  3727.  
  3728.      ____
  3729.  
  3730.      SEND
  3731.      ____
  3732.  
  3733.      Default key:   none
  3734.      Description:   Send a string to the modem (serial port).
  3735.  
  3736.      Examples:
  3737.  
  3738.           {send Fred|~~Brucker|~~%_pass%|}
  3739.  
  3740.                               Send my first and last name with
  3741.                               carriage returns and 1 second delays,
  3742.                               then send the current password and a
  3743.                               <cr>.
  3744.  
  3745.           {send ^[^[}         Send two <esc> characters.
  3746.  
  3747.           {send  }            Send a space (there must be two spaces,
  3748.                               the first is the separator).
  3749.  
  3750.           {send %line}        Send the string in the variable "line".
  3751.  
  3752.  
  3753.      NOTE:  See Appendix D in the User Guide and Reference for
  3754.      information on how to represent any character in a SEND function.
  3755.  
  3756.      _______
  3757.  
  3758.      SETDial
  3759.      _______
  3760.  
  3761.      Default key:   none
  3762.      Description:   Set parameters for dialing.
  3763.  
  3764.      Examples:
  3765.  
  3766.  
  3767.  
  3768.                    {COMMO} (tm)  Macro Programming Guide            69
  3769.  
  3770.  
  3771.           {setdial 60,15}          Set the dialing cycle timer to 60
  3772.                                    seconds and the Inter-dial Delay to
  3773.                                    15 seconds.
  3774.  
  3775.           {setd ,3}                Change only the Inter-dial Delay
  3776.                                    timer.
  3777.  
  3778.      The first argument is the dialing cycle time limit.  This is the
  3779.      number of seconds {COMMO} will allow after sending the dial
  3780.      command to the modem.  Range is from 1 to 999.
  3781.  
  3782.      The second argument is the inter-dial delay timer.  This is the
  3783.      number of seconds before {COMMO} dials the next number.  Range is
  3784.      from 1 to 999.
  3785.  
  3786.      NOTE:  Changes to dialing parameters override the Setup File
  3787.      values and remain in effect until {COMMO} is exited.
  3788.  
  3789.      See also DIAL.
  3790.  
  3791.      ______
  3792.  
  3793.      SETEsc
  3794.      ______
  3795.  
  3796.      Default key:   none
  3797.      Description:   Define a label to GOTO when Esc is pressed.
  3798.  
  3799.      General form:
  3800.  
  3801.           {setesc label}
  3802.  
  3803.                label     A label to GOTO when the user presses Esc
  3804.                          during macro execution.
  3805.  
  3806.      Switches:
  3807.  
  3808.                P1 or P   The user will be prompted with, "A macro is
  3809.                          running.  Terminate it?."  If the user
  3810.                          answers "no," macro processing will continue
  3811.                          as if nothing had happened.  If "yes,"
  3812.                          processing will GOTO the label.  If the label
  3813.                          does not exist, a STOP will be executed.  P1
  3814.                          is the default.
  3815.  
  3816.                P0        The user will not be prompted.  Processing
  3817.                          will GOTO the label if it exists, else a STOP
  3818.                          will be executed.
  3819.  
  3820.      Examples:
  3821.  
  3822.           {setesc finish}          GOTO label, with prompt.
  3823.  
  3824.  
  3825.  
  3826.                    {COMMO} (tm)  Macro Programming Guide            70
  3827.  
  3828.  
  3829.           {sete-p0 done}           GOTO label, without prompt.
  3830.           {setesc}                 Reset to no label (STOP on Esc).
  3831.  
  3832.  
  3833.      This function is used to "capture" the Esc key during macro
  3834.      execution, especially when a MACLoad is used to load a new Macro
  3835.      File.  It will help prevent accidental macro terminations.
  3836.  
  3837.      The macro at the label would typically reload COMMO.MAC, thus
  3838.      restoring the user's familiar environment.
  3839.  
  3840.      NOTE:  In the various command windows, Esc is normally used to
  3841.      exit the window.  Use Ctrl-Break to bring up the prompt.
  3842.  
  3843.      ______
  3844.  
  3845.      SETGet
  3846.      ______
  3847.  
  3848.      Default key:   none
  3849.      Description:   Set parameters for GETString functions.
  3850.  
  3851.      General form:
  3852.  
  3853.           {SETGet seconds,label,y/n/l,string}
  3854.  
  3855.                seconds   GETString timeout.  If a character is not
  3856.                          entered in the specified amount of time, the
  3857.                          macro in the second argument will be started. 
  3858.                          May be 0 to 999.  Default is 0 (disabled).
  3859.  
  3860.                label     Timeout macro.  Macro to GOTO if the time in
  3861.                          the first argument expires.  If no macro is
  3862.                          specified or if the macro label is invalid,
  3863.                          control will pass to the function following
  3864.                          the GETString.  Default is no macro.
  3865.  
  3866.                          Note that if the timer expires no variable
  3867.                          assignment will be made.  Any previous
  3868.                          assignment will be unaltered.
  3869.  
  3870.                y/n/l     Echo Status.  If this is "yes", characters
  3871.                          entered at the local or remote terminals will
  3872.                          be echoed back to the remote and displayed
  3873.                          locally.  This is the default.
  3874.  
  3875.                          If "no", characters will not be echoed to
  3876.                          either location.
  3877.  
  3878.                          If "local", characters will be displayed
  3879.                          locally, but not echoed to the remote.  This
  3880.  
  3881.  
  3882.  
  3883.                    {COMMO} (tm)  Macro Programming Guide            71
  3884.  
  3885.  
  3886.                          should be used when the remote is a host
  3887.                          system.
  3888.  
  3889.                          IMPORTANT!  This setting is independent of
  3890.                          Local Echo.  Turn on Local Echo if necessary
  3891.                          for local display of data transmitted with
  3892.                          SEND, ASCIiup, etc.
  3893.  
  3894.                string    Terminator response.  This string will be
  3895.                          sent and/or displayed locally (in accord with
  3896.                          the Echo Status) when a carriage return is
  3897.                          received (input terminated).  This is
  3898.                          typically a carriage return/linefeed.  May be
  3899.                          up to 32 characters.  Default is no string.
  3900.  
  3901.      Example:
  3902.  
  3903.           {setg 120,noget,y,^m^j}       Set GETString parameters.
  3904.  
  3905.  
  3906.      The SETGet function will set parameters for all subsequent
  3907.      GETString functions.  It may be executed at any time to modify
  3908.      the parameters.
  3909.  
  3910.      When macro processing terminates, the parameters will be reset to
  3911.      the default values.
  3912.  
  3913.      Default arguments are:   GETString timeout        0 (disabled)
  3914.                               Timeout macro            none 
  3915.                               Echo status              y (echo on)
  3916.                               Terminator response      none
  3917.  
  3918.      IMPORTANT!  Null arguments in the SETGet function will be set to
  3919.      these defaults.
  3920.  
  3921.      See also: GETString.
  3922.  
  3923.      _______
  3924.  
  3925.      SETLook
  3926.      _______
  3927.  
  3928.      Default key:   none
  3929.      Description:   Set parameters for LOOKfor functions.
  3930.  
  3931.      General form:
  3932.  
  3933.           {SETLook seconds,label,seconds,string}
  3934.  
  3935.                seconds   LOOKfor timeout.  Maximum time in seconds to
  3936.                          look for a string.  If the string is not
  3937.                          found in the allotted time, the macro in the
  3938.  
  3939.  
  3940.  
  3941.                    {COMMO} (tm)  Macro Programming Guide            72
  3942.  
  3943.  
  3944.                          second argument will be started.  May be 0 to
  3945.                          999.  Default is 0 (disabled).  
  3946.  
  3947.                label     Timeout macro.  Macro to GOTO if the time in
  3948.                          the first argument expires.  If no macro is
  3949.                          specified or if the macro label is invalid,
  3950.                          control will pass to the function following
  3951.                          the LOOKfor.
  3952.  
  3953.                seconds   Prompt timeout.  During a LOOKfor function
  3954.                          unwanted prompts may appear like "Press any
  3955.                          key" or "More [Y/n]", etc.  This argument is
  3956.                          the time in seconds to wait at a prompt (no
  3957.                          input from the modem) before sending the
  3958.                          string in the fourth argument.  Usually you
  3959.                          would send "|" or "n|".
  3960.  
  3961.                          When the response string is sent the timer is
  3962.                          restarted, allowing any number of prompts to
  3963.                          be satisfied (until the LOOKfor itself is
  3964.                          satisfied or times out).
  3965.  
  3966.                          The timer will also be restarted if any keys
  3967.                          are typed while waiting.  This allows a
  3968.                          manual response to a prompt which the macro
  3969.                          does not handle.
  3970.  
  3971.                          IMPORTANT!  The prompt timeout should be long
  3972.                          enough (or disabled entirely) to prevent the
  3973.                          response from being sent when there is a long
  3974.                          delay without a prompt.  This might occur
  3975.                          right after connection while the BBS software
  3976.                          is loading or when a "door" program is
  3977.                          loading.
  3978.  
  3979.                          Failure to heed this warning will result in
  3980.                          "n" responses to "First name?" and other
  3981.                          undesirable effects.
  3982.  
  3983.                          May be 0 to 999.  Default is 0 (disabled).
  3984.  
  3985.                string    Prompt response.  String to send when the
  3986.                          time in the third argument runs out.  May be
  3987.                          up to 32 characters.  Default is no string.
  3988.  
  3989.      Example:
  3990.  
  3991.           {setl 60,abc,4,n|}       Set LOOKfor parameters
  3992.  
  3993.  
  3994.  
  3995.                    {COMMO} (tm)  Macro Programming Guide            73
  3996.  
  3997.  
  3998.      The SETLook function will set parameters for subsequent LOOKfor
  3999.      functions and may be executed at any time to modify the
  4000.      parameters.
  4001.  
  4002.      When macro processing terminates, the parameters will be reset to
  4003.      the default values.
  4004.  
  4005.      Default arguments are:   LOOKfor timeout     0 (disabled)
  4006.                               Timeout macro       none 
  4007.                               Prompt timeout      0 (disabled)
  4008.                               Prompt response     none
  4009.  
  4010.      IMPORTANT!  Null arguments in the SETLook function will revert to
  4011.      these defaults.
  4012.  
  4013.      See also: LOOKfor, SSLOok, CALOok, GOLOok.
  4014.  
  4015.      ___________
  4016.  
  4017.      SETVariable
  4018.      ___________
  4019.  
  4020.      Default key:   none
  4021.      Description:   Assign a string to a variable name.
  4022.  
  4023.      General form:
  4024.  
  4025.           {SETVariable name,string}
  4026.  
  4027.                name      The name of the variable to which the string
  4028.                          will be assigned.
  4029.  
  4030.                string    The string may be the name of another {COMMO}
  4031.                          variable or an environment variable.  In
  4032.                          these cases further expansion is controlled
  4033.                          by switches (see below).
  4034.  
  4035.      Switches:
  4036.  
  4037.                E1 or E   This switch indicates that the second
  4038.                          argument is a DOS environment variable.  If
  4039.                          it is not found in the environment, the
  4040.                          {COMMO} variable will be set to NULL.
  4041.  
  4042.                          Note that environment variable names are CASE
  4043.                          SENSITIVE (they are usually upper case).
  4044.  
  4045.                E0        Normal variable (default).
  4046.  
  4047.                S1 or S   This switch will cause "double expansion" of
  4048.                          the second argument (indirect variable). 
  4049.                          First {COMMO} will substitute any variables
  4050.  
  4051.  
  4052.  
  4053.                    {COMMO} (tm)  Macro Programming Guide            74
  4054.  
  4055.  
  4056.                          indicated by "%" signs.  The resulting string
  4057.                          (which must NOT begin with a "%") will then
  4058.                          be treated as a variable name and expanded
  4059.                          again.
  4060.  
  4061.                          This facility may be used to create a
  4062.                          "subscript."
  4063.  
  4064.                S0        Single expansion (default).
  4065.  
  4066.      Examples:
  4067.  
  4068.           {setv net,nodeid}             Assign the string "nodeid" to
  4069.                                         the variable name "net".
  4070.  
  4071.           {setv nodeid,ggcs_bbs}        Assign the string "ggcs_bbs"
  4072.                                         to the variable name "nodeid".
  4073.  
  4074.           {setv-s bbs,nodeid}           Assuming the above examples
  4075.                                         have been executed, this will
  4076.                                         set the variable "bbs" to
  4077.                                         "ggcs_bbs".
  4078.  
  4079.           {setv-s board,%net}           Assuming the above examples
  4080.                                         have been executed, this will
  4081.                                         set the variable "board" to
  4082.                                         "ggcs_bbs".
  4083.  
  4084.           {setv-s xxx,yyy%index}        Suppose the variable "index"
  4085.                                         has the value "3".  It will be
  4086.                                         expanded first, then "yyy3"
  4087.                                         will be expanded and its value
  4088.                                         assigned to "xxx".
  4089.  
  4090.           {setv-e abc,TABLE}            Assuming a "SET TABLE=" DOS
  4091.                                         command has been executed
  4092.                                         prior to running {COMMO}, the
  4093.                                         variable "abc" will be set to
  4094.                                         the environment string.
  4095.  
  4096.           {setv abc} or {setv abc,}     Set the variable "abc" to null
  4097.                                         (it will be deleted from
  4098.                                         variable space).
  4099.  
  4100.      _____
  4101.  
  4102.      SFLOw
  4103.      _____
  4104.  
  4105.      Default key:   none
  4106.      Description:   Set Software Flow Control toggle.
  4107.  
  4108.  
  4109.  
  4110.                    {COMMO} (tm)  Macro Programming Guide            75
  4111.  
  4112.  
  4113.      Examples:
  4114.  
  4115.           {sflow}             Toggle Software Flow Control on/off.
  4116.           {sflow y}           Turn on Software Flow Control.
  4117.           {sflow n}           Turn off Software Flow Control.
  4118.  
  4119.      _____
  4120.  
  4121.      SHELl
  4122.      _____
  4123.  
  4124.      Default key:   Alt-S
  4125.      Description:   Shell to DOS.
  4126.  
  4127.      Switches:
  4128.  
  4129.                S1 or S   Swap to disk before shelling to DOS (see
  4130.                          details under EXECute, "Using the Swap to
  4131.                          Disk Switch").
  4132.  
  4133.                S0        Do not swap to disk (default).
  4134.  
  4135.      Examples:
  4136.  
  4137.           {shell}             No arguments.
  4138.           {shell-s}           Swap to disk before shelling to DOS.
  4139.  
  4140.      ______
  4141.  
  4142.      SIGNal
  4143.      ______
  4144.  
  4145.      Default key:   none
  4146.      Description:   Set state of hardware signals.
  4147.  
  4148.      Switches:
  4149.  
  4150.                D1 or D        Set DTR high.
  4151.                D0             Set DTR low.
  4152.                R1 or R        Set RTS high.
  4153.                R0             Set RTS low.
  4154.  
  4155.      Example:
  4156.  
  4157.           {signal-d0r1}            Turn off DTR, turn on RTS.
  4158.  
  4159.      The "D" and "R" switches are used to control the RS-232C signals
  4160.      DTR (Data Terminal Ready) and RTS (Request To Send).  The default
  4161.      for each switch is to leave the signal unchanged.  Use these with
  4162.      care due to interaction with Hardware Flow Control, etc.
  4163.  
  4164.  
  4165.  
  4166.                    {COMMO} (tm)  Macro Programming Guide            76
  4167.  
  4168.  
  4169.      _____
  4170.  
  4171.      SOUNd
  4172.      _____
  4173.  
  4174.      Default key:   none
  4175.      Description:   Set Master Sound toggle.
  4176.  
  4177.      Examples:
  4178.  
  4179.           {sound}             Toggle Master Sound on/off.
  4180.           {sound y}           Turn on Master Sound.
  4181.           {sound n}           Turn off Master Sound.
  4182.  
  4183.      _______
  4184.  
  4185.      SPDCtrl
  4186.      _______
  4187.  
  4188.      Default key:   none
  4189.      Description:   Serial port display control.
  4190.  
  4191.      Examples:
  4192.  
  4193.           {spdc y}            Serial port display is ON.
  4194.           {spdc n}            Serial port display is OFF.
  4195.  
  4196.      This function will suppress display of any data received from the
  4197.      serial port.  It can be used when a "clean" display is desired
  4198.      during automated procedures.
  4199.  
  4200.      TIPS on using SPDCtrl:
  4201.  
  4202.      >    Serial port display can be suppressed only while a macro is
  4203.           running (it will be restored to ON at macro termination).
  4204.  
  4205.      >    ANSI control sequences are not processed while the display
  4206.           is OFF (Terminal Emulation effectively reverts to TTY).
  4207.  
  4208.      >    LOOKfor will function normally, but remember that ANSI
  4209.           sequences are not stripped.  Make a manual run using TTY
  4210.           emulation to see what the LOOKfor will see.
  4211.  
  4212.      >    SCREEN Capture Mode will not capture any of the incoming
  4213.           data.  Use RAW mode or FILTER mode instead (FILTER capture
  4214.           will be affected by the Translate Table, but will still
  4215.           contain ANSI sequences).
  4216.  
  4217.  
  4218.  
  4219.                    {COMMO} (tm)  Macro Programming Guide            77
  4220.  
  4221.  
  4222.      _______
  4223.  
  4224.      SPOCtrl
  4225.      _______
  4226.  
  4227.      Default key:   none
  4228.      Description:   Serial port output control.
  4229.  
  4230.      Examples:
  4231.  
  4232.           {spoc y}            Serial port output is ON.
  4233.           {spoc n}            Serial port output is OFF.
  4234.  
  4235.      This function will inhibit any data from being sent to the serial
  4236.      port.  All other program operations will be normal.  It is used
  4237.      for "local mode" in host macros (no data is sent to the modem).
  4238.  
  4239.      TIPS on using SPOCtrl:
  4240.  
  4241.      >    Serial port output can be inhibited only while a macro is
  4242.           running (it will be restored to ON at macro termination).
  4243.  
  4244.      >    Internal protocols will not operate properly if serial port
  4245.           output is turned OFF.
  4246.  
  4247.      ______
  4248.  
  4249.      SSLOok
  4250.      ______
  4251.  
  4252.      Default key:   none
  4253.      Description:   Set up an additional string to look for during a
  4254.                     subsequent LOOKfor function.
  4255.  
  4256.      General form:
  4257.  
  4258.           {SSLOok name,target}
  4259.  
  4260.                name      The name of a string variable (MUST be a
  4261.                          variable).
  4262.  
  4263.                target    The ASCII string to look for.  The string
  4264.                          begins following the "," and is terminated by
  4265.                          the "}".
  4266.  
  4267.      Switches:
  4268.  
  4269.                R or R1   Send a carriage return after sending the
  4270.                          variable string to the serial port.
  4271.  
  4272.                R0        Do not send a carriage return (default).
  4273.  
  4274.  
  4275.  
  4276.                    {COMMO} (tm)  Macro Programming Guide            78
  4277.  
  4278.  
  4279.      Example:
  4280.  
  4281.           {setv ss_r,|} {setv ss_nr,n|}
  4282.           ...
  4283.           {sslo-r _pas,password:}
  4284.           {sslo ss_r,Press enter to continue}
  4285.           {sslo ss_nr,Do you want to log off?}
  4286.           {look command?} ...
  4287.  
  4288.      SSLOok is used in conjunction with LOOKfor.  When the target
  4289.      string appears, the string in the variable is sent to the serial
  4290.      port.  The LOOKfor continues to look for all specified strings.
  4291.  
  4292.      See LOOKfor for details, examples and tips on using SSLOok.
  4293.  
  4294.      See also: CALOok, GOLOok, SETLook.
  4295.  
  4296.      __________
  4297.  
  4298.      STATusline
  4299.      __________
  4300.  
  4301.      Default key:   none
  4302.      Description:   Set Status Line toggle.
  4303.  
  4304.      IMPORTANT!  The Status Line is {COMMO}'s instrument panel.  You
  4305.      should not turn it off until you are familiar with operating the
  4306.      program.
  4307.  
  4308.      Examples:
  4309.  
  4310.           {statusline}        Toggle Status Line on/off.
  4311.           {status y}          Turn on Status Line.
  4312.           {status n}          Turn off Status Line.
  4313.  
  4314.      When the Status Line is off (not visible), the bottom line of the
  4315.      display becomes part of the Terminal Screen.
  4316.  
  4317.      The STATusline function is ignored while in Chat Mode.
  4318.  
  4319.      ____
  4320.  
  4321.      STOP
  4322.      ____
  4323.  
  4324.      Default key:   none
  4325.      Description:   Halt macro execution.
  4326.  
  4327.      Examples:
  4328.  
  4329.           {stop}              No arguments.
  4330.           {}                  Short form.
  4331.  
  4332.  
  4333.  
  4334.                    {COMMO} (tm)  Macro Programming Guide            79
  4335.  
  4336.  
  4337.  
  4338.      STOP always returns {COMMO} to manual operation in the Terminal
  4339.      Screen.  It should be used to end login macros.
  4340.  
  4341.      _____
  4342.  
  4343.      STRAn
  4344.      _____
  4345.  
  4346.      Default key:   none
  4347.      Description:   Maintain Send Translate Table.
  4348.  
  4349.      Switches:
  4350.  
  4351.                I1 or I   Initialize Send Translate Table to default
  4352.                          values (consecutive 0 to 255).
  4353.  
  4354.                I0        Do not initialize (default).
  4355.  
  4356.      Examples:
  4357.  
  4358.           {stran y}           Turn send translation ON.
  4359.  
  4360.           {stran-i n}         Initialize the table and turn it OFF.
  4361.  
  4362.           {stran-i y,92,47}   Initialize the table, turn send
  4363.                               translation ON, change "\" to "/".
  4364.  
  4365.           {stran}             Toggle send translation ON/OFF.
  4366.  
  4367.           {stran #13,65,78,#13,78,65,#13,97,110,#13,110,97}
  4368.                               ROT13 translation.  This swaps the first
  4369.                               13 letters of the alphabet for the
  4370.                               second 13.
  4371.  
  4372.      Rules for STRAn arguments are the same as for the {str=} item in
  4373.      the Setup File.  In addition, "n" may be used as the first
  4374.      argument to turn send translation OFF at any time.
  4375.  
  4376.      See "Edit Setup File" in the User Guide and Reference for details
  4377.      and more examples.
  4378.  
  4379.      TIPS on using STRAn:
  4380.  
  4381.      >    Some control characters are unaffected by translation when
  4382.           certain features are enabled.  Examples:  XON (17) and XOFF
  4383.           (19) are not translated when Software Flow Control is on. 
  4384.           When ENQ/ACK emulation is on, an ACK sent in response to an
  4385.           ENQ will not be translated.
  4386.  
  4387.      >    In GETString, data echoed to the modem (and displayed
  4388.           locally) will be translated with the Send Translate Table
  4389.  
  4390.  
  4391.  
  4392.                    {COMMO} (tm)  Macro Programming Guide            80
  4393.  
  4394.  
  4395.           (it may be necessary to turn send translation off during
  4396.           certain GETString functions).
  4397.  
  4398.      See also RTRAn.
  4399.  
  4400.      _________
  4401.  
  4402.      SUBString
  4403.      _________
  4404.  
  4405.      Default key:   none
  4406.      Description:   Move a substring to a variable.
  4407.  
  4408.      General form:
  4409.  
  4410.           {SUBString name,start,count,string}
  4411.  
  4412.                name      The name of the variable to which the
  4413.                          substring will be assigned.
  4414.  
  4415.                start     The starting character number (first
  4416.                          character is "1").  If it is negative,
  4417.                          {COMMO} will count in from the end of the
  4418.                          string.
  4419.  
  4420.                          If it is too large and positive, the
  4421.                          substring will be null.
  4422.  
  4423.                          If it is too large and negative, the
  4424.                          substring will start at the beginning of the
  4425.                          string.
  4426.  
  4427.                count     The number of characters to use.  If the
  4428.                          number is too large, {COMMO} will use as many
  4429.                          as possible.  If the count is 0, the
  4430.                          substring will be null.
  4431.  
  4432.                string    The string to use.
  4433.  
  4434.      Examples:
  4435.  
  4436.           {subs var-sub,2,4,abcdefgh}        Set "var-sub" to "bcde".
  4437.           {subs newvar,-5,20,abcdefgh}       Set "newvar" to "defgh".
  4438.  
  4439.      _______
  4440.  
  4441.      SXMOdem
  4442.      _______
  4443.  
  4444.      Default key:   none
  4445.      Description:   Send a file using the Xmodem protocol.
  4446.  
  4447.  
  4448.  
  4449.                    {COMMO} (tm)  Macro Programming Guide            81
  4450.  
  4451.  
  4452.      Switches:
  4453.  
  4454.                See SYMOdem (switches are the same).
  4455.  
  4456.      Example:
  4457.  
  4458.           {sxmo-ka c:\ul\file.zip}      Send "file.zip" using 1024
  4459.                                         byte block size (Xmodem-1k),
  4460.                                         sound the alarm.
  4461.  
  4462.      Only one file may be sent with each SXMOdem function.
  4463.  
  4464.      See SYMOdem for tips that apply to both SXMOdem and SYMOdem.
  4465.  
  4466.      See also RXMOdem, SYMOdem.
  4467.  
  4468.      _______
  4469.  
  4470.      SYMOdem
  4471.      _______
  4472.  
  4473.      Default key:   none
  4474.      Description:   Send a file using the Ymodem Batch protocol.
  4475.  
  4476.      Switches:
  4477.  
  4478.                K1 or K   Use 1024 byte block size.
  4479.                K0        Use 128 byte block size (default).
  4480.  
  4481.                D1 or D   Cancel transfer if carrier detect is lost
  4482.                          (default).
  4483.                D0        Ignore state of carrier detect.
  4484.  
  4485.                A1 or A   Sound the alarm at end of transfer.
  4486.                A0        Do not sound the alarm (default).
  4487.  
  4488.                W         Wait for a keypress at end of transfer.
  4489.                Wn        Wait for "n" seconds, "n" may range from 0 to
  4490.                          999.  Press a key to cancel the wait.
  4491.                          Note:  Default (no "W" switch) is no wait.
  4492.  
  4493.      Examples:
  4494.  
  4495.           {symo-ka %uldir\*.zip}        Send all .ZIP files in the
  4496.                                         upload directory using 1024
  4497.                                         byte block size, sound the
  4498.                                         alarm.
  4499.  
  4500.           {symo-k c:\subdir\*.*,@c:\ul\file.lst,info.txt,a:*.qw?}
  4501.                                         Send all files listed using
  4502.                                         1024 byte block size.
  4503.  
  4504.  
  4505.  
  4506.                    {COMMO} (tm)  Macro Programming Guide            82
  4507.  
  4508.  
  4509.      Any combination of file specifications may be listed in the
  4510.      SYMOdem function (separated with commas).  These may include
  4511.      wildcard specifiers (*,?), the indirect file specifier (@) and
  4512.      any single files.
  4513.  
  4514.      If a filespec is preceded with the "@" sign, it will be assumed
  4515.      to be an "indirect file."  This means that it is a text file
  4516.      containing a list of filespecs.  Filespecs should be listed one
  4517.      per line and each line should end with a cr/lf.  Each filespec
  4518.      may contain wildcards.  For example:
  4519.  
  4520.           c:\subdir\*.*
  4521.           info.txt
  4522.           a:*.qw?
  4523.  
  4524.      TIPS on using SYMOdem and SXMOdem:
  4525.  
  4526.      >    CRC vs. Csum mode is established by the receiver.
  4527.  
  4528.      >    Use of "G" method is established by the receiver.
  4529.  
  4530.      >    Some conditions that will cancel a transfer:
  4531.             1) 10 consecutive errors.
  4532.             2) Any error when "G" method is used.
  4533.             3) The receiver has transmitted CAN (^X) characters.
  4534.  
  4535.      >    The Exit Code (test with IFER) will be set at the end of the
  4536.           transfer.  The Exit Code will also be stored in the variable
  4537.           "_err".  0 means success, 1 means failure.
  4538.  
  4539.      >    If the Usage Log is enabled, an entry will be made after
  4540.           each file is transferred (or if a transfer is cancelled).
  4541.  
  4542.      See also RYMOdem, SXMOdem.
  4543.  
  4544.      _______
  4545.  
  4546.      TOGGles
  4547.      _______
  4548.  
  4549.      Default key:   Alt-T
  4550.      Description:   Set various toggle parameters.
  4551.  
  4552.      Example:
  4553.  
  4554.           {toggles}                Open Set Toggles window.
  4555.  
  4556.  
  4557.  
  4558.                    {COMMO} (tm)  Macro Programming Guide            83
  4559.  
  4560.  
  4561.      ______
  4562.  
  4563.      UNMArk
  4564.      ______
  4565.  
  4566.      Default key:   none
  4567.      Description:   Unmark Dialing Directory entries.
  4568.  
  4569.      Switches:
  4570.  
  4571.                L1 or L   Unmark last-dialed entry only.
  4572.                L0        Unmark all or listed entries (default).
  4573.  
  4574.      Examples:
  4575.  
  4576.           {unmark joes-bbs,file-city}        Unmark listed entries.
  4577.           {unmark}                           Unmark all entries.
  4578.           {unmark-L}                         Unmark last-dialed entry.
  4579.  
  4580.      NOTE:  When the "L" switch is present, any Dialing Strings listed
  4581.      will be ignored.
  4582.  
  4583.      Dialing Strings may be separated by spaces or commas.
  4584.  
  4585.      {COMMO} will search the Dialing Directory for each string and
  4586.      unmark the first entry where a match is found.  Case is ignored.
  4587.  
  4588.      The strings may consist of any part of a Dialing Directory entry
  4589.      line (including strings contained within curly braces), but must
  4590.      NOT contain any spaces, commas or curly braces.
  4591.  
  4592.      See also: DIAL, MARK.
  4593.  
  4594.      _____
  4595.  
  4596.      VIDEo
  4597.      _____
  4598.  
  4599.      Default key:   none
  4600.      Description:   Change to an alternate hardware video mode.
  4601.  
  4602.      Switches:
  4603.  
  4604.                M1 or M   Change to the alternate display mode.
  4605.                M0        Change back to the normal display mode.
  4606.  
  4607.      Examples:
  4608.  
  4609.           {video-m1}          Change to the alternate mode.
  4610.           {video-m0}          Change back to the normal mode.
  4611.  
  4612.  
  4613.  
  4614.                    {COMMO} (tm)  Macro Programming Guide            84
  4615.  
  4616.  
  4617.      The "alternate" mode is defined by Setup File item {avm=}.  The
  4618.      "normal" mode is the mode in effect when you start {COMMO}.
  4619.  
  4620.      _____
  4621.  
  4622.      VTCUr
  4623.      _____
  4624.  
  4625.      Default key:   none
  4626.      Description:   Define a VT102 cursor (arrow) key.
  4627.  
  4628.      Example:
  4629.  
  4630.           {vtcur ^[[A|^[OA}        Define up-arrow key strings.
  4631.  
  4632.      The first string is sent when cursor mode is active; the second
  4633.      string is sent when application mode is active (these modes are
  4634.      controlled by the host).
  4635.  
  4636.      The two strings must be separated by a "|".  Use "^m" for
  4637.      carriage return if necessary.
  4638.  
  4639.      See also VTPAd.
  4640.  
  4641.      _____
  4642.  
  4643.      VTPAd
  4644.      _____
  4645.  
  4646.      Default key:   none
  4647.      Description:   Define a VT102 keypad key.
  4648.  
  4649.      Example:
  4650.  
  4651.           {vtpad 5|^[Ou}           Define keypad "5" key strings.
  4652.  
  4653.      The first string is sent when numeric mode is active; the second
  4654.      string is sent when application mode is active (these modes are
  4655.      controlled by the host).
  4656.  
  4657.      The two strings must be separated by a "|".  Use "^m" for
  4658.      carriage return if necessary.
  4659.  
  4660.      See also VTCUr.
  4661.  
  4662.      ______
  4663.  
  4664.      WCLOse
  4665.      ______
  4666.  
  4667.      Default key:   none
  4668.      Description:   Close the write file.
  4669.  
  4670.  
  4671.  
  4672.                    {COMMO} (tm)  Macro Programming Guide            85
  4673.  
  4674.  
  4675.  
  4676.      Example:
  4677.  
  4678.           {wclose}            No arguments.
  4679.  
  4680.      NOTE:  The write file will be closed automatically when the macro
  4681.      terminates (STOP, EXIT, etc.).
  4682.  
  4683.      See also WOPEn, WRITE.
  4684.  
  4685.      _____
  4686.  
  4687.      WOPEn
  4688.      _____
  4689.  
  4690.      Default key:   none
  4691.      Description:   Open a file for writing.
  4692.  
  4693.      Switches:
  4694.  
  4695.                A1 or A   Open the file in "append" mode.  New lines
  4696.                          written to the file will be added at the end. 
  4697.                          If the file doesn't exist, it will be
  4698.                          created.
  4699.  
  4700.                A0        Open the file in "create" mode.  If the file
  4701.                          exists, it will be erased (default).
  4702.  
  4703.      Examples:
  4704.  
  4705.           {wopen c:\bbs\file.txt}       Open the file in create mode.
  4706.  
  4707.           {wopen-a c:\data\word.fil}    Open the file in append mode.
  4708.  
  4709.      TIP on using WOPEn:
  4710.  
  4711.      >    Only one file may be opened for writing (and one for
  4712.           reading).
  4713.  
  4714.      See also WRITe, WCLOse.
  4715.  
  4716.      _____
  4717.  
  4718.      WRITe
  4719.      _____
  4720.  
  4721.      Default key:   none
  4722.      Description:   Write a string to the write file.
  4723.  
  4724.      Examples:
  4725.  
  4726.  
  4727.  
  4728.                    {COMMO} (tm)  Macro Programming Guide            86
  4729.  
  4730.  
  4731.           {write %nextline}        Write the contents of the variable
  4732.                                    "nextline" to the write file.
  4733.  
  4734.           {write}                  Write a carriage return/linefeed
  4735.                                    only (blank line) to the file.
  4736.  
  4737.           {write %num%> }          Write the contents of "num"
  4738.                                    followed by a ">" and a space.
  4739.  
  4740.      TIPS on writing to files:
  4741.  
  4742.      >    A file must be open for writing or a macro error will
  4743.           result.
  4744.  
  4745.      >    The string will be written as one line, terminated by a
  4746.           carriage return/linefeed.
  4747.  
  4748.      >    Control character conversion is NOT performed on the write
  4749.           string.
  4750.  
  4751.      >    A macro error will result if the disk is full.
  4752.  
  4753.      See also WOPEn, WCLOse
  4754.  
  4755.  
  4756.  
  4757.                    {COMMO} (tm)  Macro Programming Guide            87
  4758.  
  4759.  
  4760.      ========================================
  4761.      Appendix A   Table of {COMMO} Key-labels
  4762.      ========================================
  4763.  
  4764.      Key-labels are also macro labels with the added advantage that
  4765.      the macro can be started by pressing the associated key from the
  4766.      Terminal Screen.  Most "extended" keys may be assigned this way. 
  4767.      If the same key-label appears more than once, the first
  4768.      occurrence will be used.  Note that key-labels are case
  4769.      insensitive.  The caret (^) indicates the Ctrl key.
  4770.  
  4771.      Enhanced keyboard key-labels are listed below.
  4772.  
  4773.  
  4774.           Key Name     Key-label     Key Name     Key-label
  4775.           ________     _________     ________     _________
  4776.  
  4777.           Normal-F1     nf1   ...    Normal-F10    nf0
  4778.           Ctrl-F1       cf1   ...    Ctrl-F10      cf0
  4779.           Shift-F1      sf1   ...    Shift-F10     sf0
  4780.           Alt-F1        af1   ...    Alt-F10       af0
  4781.  
  4782.           Alt-A         ala   ...    Alt-Z         alz
  4783.           Alt-1         al1   ...    Alt-0         al0
  4784.           Alt =         al=          Alt -         al-
  4785.  
  4786.           Escape        esc          Grey *        gr*
  4787.           Grey -        gr-          Grey +        gr+
  4788.  
  4789.           Backspace     bsp          ^Backspace    cbs
  4790.           Tab           tab          Shift-tab     stb
  4791.           Enter         ent          ^Enter        cen
  4792.  
  4793.           Home          hom          End           end
  4794.           PgUp          pgu          PgDn          pgd
  4795.           Up-Arrow      upa          Down-Arrow    dna
  4796.           Left-Arrow    lfa          Right-Arrow   rta
  4797.           Insert        ins          Delete        del
  4798.  
  4799.           ^Home         chm          ^End          cnd
  4800.           ^PgUp         cpu          ^PgDn         cpd
  4801.           ^Right-Arrow  cra          ^Left-Arrow   cla
  4802.  
  4803.           Keypad-0      kp0   ...    Keypad-9      kp9
  4804.           Keypad-.      kp.          ^PrtSc        cpr
  4805.  
  4806.  
  4807.  
  4808.                    {COMMO} (tm)  Macro Programming Guide            88
  4809.  
  4810.  
  4811.      Enhanced Keyboard Key-labels
  4812.      ============================
  4813.  
  4814.      IMPORTANT!  To use the following keys you must tell {COMMO} to
  4815.      test for the enhanced keyboard.  The item {tek=yes} must appear
  4816.      in your Setup File.
  4817.  
  4818.           Normal-F11    nfa          Normal-F12    nfb
  4819.           Ctrl-F11      cfa          Ctrl-F12      cfb
  4820.           Shift-F11     sfa          Shift-F12     sfb
  4821.           Alt-F11       afa          Alt-F12       afb
  4822.  
  4823.           Alt-[         al[          Alt-]         al]
  4824.           Alt-;         al;          Alt-'         al'
  4825.           Alt-,         al<          Alt-.         al.
  4826.           Alt-/         al/          Alt-\         al\
  4827.           Alt-*         al*          Alt-`         al`
  4828.           Center Key    cky
  4829.  
  4830.      The Center Key is the Keypad 5 with Numlock off.
  4831.  
  4832.      The keys in the second group may also work with the 83-key
  4833.      keyboard if your BIOS supports the enhanced keyboard.
  4834.  
  4835.  
  4836.  
  4837.                    {COMMO} (tm)  Macro Programming Guide            89
  4838.  
  4839.  
  4840.      =======================================
  4841.      Appendix B   List of Reserved Variables
  4842.      =======================================
  4843.  
  4844.      USER-DEFINED Reserved Variables
  4845.      -------------------------------
  4846.  
  4847.           _modini        Modem Initialization String
  4848.           _dialpf        Default dialing prefix
  4849.           _dialsf        Default dialing suffix
  4850.           _dialsr        Dialing success response(s)
  4851.           _dialfr        Dialing failure response(s)
  4852.           _dialir        Inter-dial Delay response(s)
  4853.           _dialrt        Dialing response text, available (1) after a
  4854.                          dialing attempt if _dtc = 1 or 2, or (2) in
  4855.                          the Inter-dial Delay macro.
  4856.           _uselog        Pathname of Usage Log
  4857.           _menux         Menu display string, x = 1, 2, 3, etc.
  4858.           _mlabel        List of macro labels for pop-up menu 
  4859.           _mcolor        Colors used with pop-up menu: text,border
  4860.  
  4861.      BUILT-IN Variables
  4862.      ------------------
  4863.  
  4864.           _hom      {COMMO} home directory: c:\commo\, etc.
  4865.           _set      Filename of Setup File, usually COMMO.SET
  4866.           _fon      Filename of Dialing Directory, usually COMMO.FON
  4867.           _mac      Filename of default Macro File, usually COMMO.MAC
  4868.           _cap      Current Capture File pathname
  4869.           _scr      Current Screen Image File pathname
  4870.  
  4871.           _err      Errorlevel from last EXEC-D or internal file
  4872.                     transfer protocol
  4873.           _dfc      Disk full on capture: 0=no, 1=yes; reset when
  4874.                     Capture File is opened, set when disk is full
  4875.           _pos      Position in string
  4876.           _len      Length of string
  4877.  
  4878.           _por      Current serial port number: 1, 2, etc.
  4879.           _spe      Current serial port speed: 2400, 9600, etc.
  4880.           _fmt      Current serial port data format: 8n1, 7e1, etc.
  4881.           _mod      Last speed reported by modem
  4882.           _pad      Current serial port address: 03F8, 02E8, etc.
  4883.           _irq      Current IRQ number: 4, 3, etc.
  4884.           _nci      Number of characters in input buffer (received and
  4885.                     not yet displayed)
  4886.  
  4887.           _dtc      Dialing termination code (available after each
  4888.                     dialing attempt).  Values are:
  4889.                          0 = no systems were marked
  4890.                          1 = successful connection
  4891.                          2 = failure response received
  4892.  
  4893.  
  4894.  
  4895.                    {COMMO} (tm)  Macro Programming Guide            90
  4896.  
  4897.  
  4898.                          3 = timed out
  4899.                          4 = operator intervention
  4900.  
  4901.           _rem      Remainder from last DIVIde
  4902.           _pas      Current Password String
  4903.           _ela      Elapsed time in minutes
  4904.  
  4905.           _dat      Full date (format defined in Setup File)
  4906.           _mon      Month, mm
  4907.           _day      Day of the month, dd
  4908.           _yea      Year, yy
  4909.           _dwn      Numeric day of the week: 1=Mon, ... , 7=Sun
  4910.           _dwt      Text day of the week: Mon, Tue, ...
  4911.  
  4912.           _tim      Full time (format defined in Setup File)
  4913.           _24h      24 hour, hh
  4914.           _12h      12 hour, hh
  4915.           _amp      Am/pm indicator, xm
  4916.           _min      Minute, mm
  4917.           _sec      Second, ss
  4918.  
  4919.           _row      Current cursor row
  4920.           _col      Current cursor column
  4921.  
  4922.  
  4923.  
  4924.                    {COMMO} (tm)  Macro Programming Guide            91
  4925.  
  4926.  
  4927.      ============================================
  4928.      Appendix C   Macro Functions Listed by Class
  4929.      ============================================
  4930.  
  4931.      Variable manipulation
  4932.      ---------------------
  4933.  
  4934.           SETVariable    Assign a string to a variable name
  4935.           INCRement      Increase a numeric variable
  4936.           DECRement      Decrease a numeric variable
  4937.           MULTiply       Multiply a numeric variable
  4938.           DIVIde         Divide a numeric variable
  4939.           INSTring       Find a string within a string
  4940.           SUBString      Move a substring to a variable
  4941.           LENGth         Determine the length of a string
  4942.  
  4943.      Looking for text
  4944.      ----------------
  4945.  
  4946.           AUTO           Auto Receive
  4947.           SETLook        Set LOOKfor parameters
  4948.           LOOKfor        Look for string from port
  4949.           SSLOok         Additional string, send variable
  4950.           CALOok         Additional string, call submacro
  4951.           GOLOok         Additional string, go to macro
  4952.  
  4953.      File Input/Output
  4954.      -----------------
  4955.  
  4956.           ROPEn          Open a file for reading
  4957.           READ           Read from a file to a variable
  4958.           RCLOse         Close the read file
  4959.           WOPEn          Open a file for writing
  4960.           WRITe          Write to a file from a variable
  4961.           WCLOse         Close the write file
  4962.  
  4963.      Dialing/connect/disconnect
  4964.      --------------------------
  4965.  
  4966.           SETDial        Set dialing timers
  4967.           DIAL           Dialing Directory
  4968.           DPARms         Set dialing default parameters
  4969.           HANGup         Drop DTR to hangup
  4970.           MARK           Mark numbers for dialing
  4971.           UNMArk         Unmark Dialing Directory entries
  4972.           ABAUd          AutoBaud toggle
  4973.  
  4974.      Modem control
  4975.      -------------
  4976.  
  4977.           PARMs          Set current terminal parameters
  4978.           LOCAlecho      Local Echo toggle
  4979.  
  4980.  
  4981.  
  4982.                    {COMMO} (tm)  Macro Programming Guide            92
  4983.  
  4984.  
  4985.           INITmodem      Send modem init string
  4986.           HFLOW          Hardware flow control
  4987.           SFLOw          Software flow control
  4988.           BREAk          Send a Break signal
  4989.           LIGHts         Signal Lights toggle
  4990.           SIGNal         Set state of hardware signals
  4991.           SPOCtrl        Serial port output control
  4992.  
  4993.      Send/receive data
  4994.      -----------------
  4995.  
  4996.           ASCIiup        ASCII Upload
  4997.           SEND           Send a text string
  4998.           CAPMode        Set Capture Mode
  4999.           CAPTure        Capture File Options
  5000.           SETGet         Set GETString parameters
  5001.           GETString      Get a string from the modem
  5002.           RXMOdem        Receive a file using Xmodem
  5003.           SXMOdem        Send a file using Xmodem
  5004.           RYMOdem        Receive a file using Ymodem
  5005.           SYMOdem        Send a file using Ymodem
  5006.           PASSword       Send current password
  5007.           RTRAn          Maintain Receive Translate Table
  5008.           STRAn          Maintain Send Translate Table
  5009.           VTCUr          VT102 cursor key strings
  5010.           VTPAd          VT102 keypad key strings
  5011.  
  5012.      Testing
  5013.      -------
  5014.  
  5015.           COMPare        Compare a variable to a string
  5016.           IFCOndition    Test conditions set by COMPare
  5017.           IFERrorlevel   Test Exit Codes
  5018.           IFEXist        Test for existence of file(s)
  5019.           IFCArrier      Test for presence of carrier detect
  5020.  
  5021.      Macro control
  5022.      -------------
  5023.  
  5024.           CALL           Execute a macro
  5025.           RETUrn         Return from a CALL
  5026.           PUSHstack      Push a location to the macro stack
  5027.           POPStack       Pop from the macro stack
  5028.           GOTO           Transfer control to a label
  5029.           STOP           Stop macro processing
  5030.           MACLoad        Load a new Macro File
  5031.           PAUSe          Pause for interval 1-999 seconds
  5032.           HOLD           Hold until specified 24 hr time
  5033.           NOCArrier      Set a label to GOTO when carrier is lost
  5034.           SETEsc         Set a label to GOTO on Esc
  5035.  
  5036.  
  5037.  
  5038.                    {COMMO} (tm)  Macro Programming Guide            93
  5039.  
  5040.  
  5041.      Video/sound related
  5042.      -------------------
  5043.  
  5044.           CLEAr          Clear Screen
  5045.           CURSor         Terminal Screen cursor toggle
  5046.           DISPlay        Display a string to the screen
  5047.           SCREen         Screen Image Save
  5048.           SPDCtrl        Serial port display control
  5049.           STATusline     Status Line on/off toggle
  5050.           VIDEo          Change to an alternate video mode
  5051.  
  5052.           SOUNd          Master Sound toggle
  5053.           ALARm          Ring the alarm
  5054.           BEEP           Sound a beep
  5055.  
  5056.      Miscellaneous
  5057.      -------------
  5058.  
  5059.           CHATmode       Chat Mode toggle
  5060.           DOORway        Doorway Mode toggle
  5061.           ELAPse         Reset the elapsed timer
  5062.           EDIT           Edit a file
  5063.           EXECute        Execute a DOS command
  5064.           EXIT           Exit {COMMO}
  5065.           HELP           Online Help topic
  5066.           INPUt          Input from the keyboard
  5067.           KEYStuff       Put key codes into the keyboard buffer
  5068.           MACRo          Macro Processor window
  5069.           MENU           Create a pop-up macro menu
  5070.           NOOP           No-op function, does nothing
  5071.           OFFLog         Make an {Off} entry in the Usage Log
  5072.           PRINtlog       Print Log toggle
  5073.           SCROllback     Display Scrollback Buffer
  5074.           SHELl          Shell to DOS
  5075.           TOGGles        Set Toggles
  5076.  
  5077.  
  5078.                                   - end -
  5079.  
  5080.