advr.hlp (Topic list)
OPTION BASE Statement Details
  Summary  Details  Example                Contents  Index  Back
──────────────────────────────────────────────────────────────────────────────
 OPTION BASE {0 | 1}
 
 Usage Notes
   ■ The TO clause in the DIM statement provides an easier, more flexible way
     to control the range of an array's subscripts. See: DIM Statement
 
   ■ The default base is 0. If the lower bound of an array subscript is not
     explicitly set, OPTION BASE can be used to change the default lower
     bound to 1. For example, if the following statement is encountered, the
     default lowest value of an array subscript is 1:
 
         OPTION BASE 1
 
   ■ The OPTION BASE statement is never required. If it is used, however, it
     must precede any array declarations.
 
   ■ The OPTION BASE statement can be used only once in a module (source
     file) and can only appear in the module-level code.
 
   ■ Chained programs can have an OPTION BASE statement if no arrays are
     passed in COMMON between them in a COMMON block, or if the specified
     base is identical in the chained programs. The chained-to program
     inherits the OPTION BASE value of the chaining program if OPTION BASE
     is omitted in the latter. See: CHAIN Statement  COMMON Statement