home *** CD-ROM | disk | FTP | other *** search
/ Share Gallery 1 / share_gal_1.zip / share_gal_1 / UT / UT214.ZIP / SEBFU40.LZH / MATH.DOC < prev    next >
Text File  |  1991-09-17  |  3KB  |  106 lines

  1.  
  2.                              M A T H     Ver. 4.0
  3.  
  4.  
  5.                     (C)1989,1990,1991  Scanlon Enterprises
  6.  
  7.  
  8.  
  9.  
  10.  
  11.        MATH is a small utility to perform either addition or subtraction 
  12.        on an environment variable. This utility will roll over values 
  13.        larger than 65535, IE... if 30 is added to 65530 the result is 5, 
  14.        and an overflow errorlevel will be generated. MATH will also roll 
  15.        over numbers which would result in negative numbers, IE.. if 30 
  16.        is subtracted from 20 the result is 65520, and an overlfow 
  17.        errorlevel will be generated. This utility can be used to aid in 
  18.        developing loop counters for batch files. IE... create an 
  19.        environment variable set to 10, and subtract one for each pass of 
  20.        the section of code, for 10 loops.
  21.  
  22.  
  23.        Syntax : MATH /-n /+n /Vvar
  24.  
  25.  
  26.  
  27.        Where : '/-n' subtracts 'n' from an environment variable
  28.                '/+n' adds 'n' from an environment variable
  29.                '/Vvar' tells MATH to use variable 'var'
  30.  
  31.  
  32.        Defaults: 'var' is set to ADD as a default
  33.  
  34.  
  35.        ERRORLEVELS: 255 (0FF) = Program problem (call Author)
  36.                     254 (0FE) = Invalid option
  37.                     253 (0FD) = Positive overflow
  38.                     252 (0FC) = Negative overflow
  39.  
  40.  
  41.        EXAMPLE:
  42.  
  43.                ECHO OFF
  44.                CLS
  45.                SET ADD=10
  46.                :LOOP1
  47.                {Do several things}
  48.                MATH /-1          {subtract 1 from var}
  49.                IF NOT ADD==0 GOTO LOOP1  {Do loop 10 times}
  50.  
  51.  
  52.  
  53.        For additional usage and information on using these utilities see 
  54.        the file SEBFU.DOC or BATUT.DOC.
  55.  
  56.  
  57.  
  58.  
  59.  
  60.  
  61.  
  62.  
  63.       Page 1 of 2
  64.  
  65.                               M A T H    Ver. 4.0
  66.  
  67.  
  68.                     (C)1989,1990,1991  Scanlon Enterprises
  69.  
  70.  
  71.  
  72.                              O R D E R     F O R M
  73.  
  74.  
  75.  
  76.  
  77.        MATH registration ..................................... $1.00
  78.  
  79.  
  80.  
  81.  
  82.        What you get :
  83.  
  84.        Unlimited usage of MATH, and phone or write in support. You 
  85.        will also be placed on our mailing list for future updates and 
  86.        new products.
  87.  
  88.        We are offering this utility seperate from SEBFU as a favor to 
  89.        users who do NOT wish to use many of the SEBFU utilities.
  90.  
  91.        This utility is automatically registered to you when you register 
  92.        SEBFU as a product (see REG.DOC). Registering SEBFU as a product 
  93.        is a better bargin, as each utility will cost less than $ .25 
  94.        each.
  95.  
  96.  
  97.        Vendors:
  98.  
  99.        You may distribute MATH seperately, provided this document is 
  100.        distributed as well. Any reasonable fee may be charged.
  101.  
  102.  
  103.        Send your order to : SCANLON ENTERPRISES
  104.                             38354 17TH ST E.
  105.                             PALMDALE, CA 93550
  106.