bas7qck.hlp (Table of Contents; Topic list)
SUB Statement
  Syntax  Details  Example                 Contents  Index  Back
──────────────────────────────────────────────────────────────────────────────
SUB globalname[(parameterlist)] [STATIC]
  [statementblock]
[EXIT SUB]
  [statementblock]
END SUB
 
    ■ globalname       A variable name up to 40 characters long. This
                       name cannot appear in any other SUB or FUNCTION
                       statement in the same program or the user library.
                       The name cannot include a type-declaration character.
    ■ parameterlist    The list of variables, representing parameters,
                       that will be passed to the SUB when it is called.
                       called. See Details for the syntax of parameterlist.
    ■ STATIC           Indicates the function's local variables are to
                       be saved between calls.
    ■ EXIT SUB         Causes an immediate exit of a SUB procedure.
                       Program execution continues with the statement after
                       the CALL statement.
 
See Also    DECLARE (BASIC)    CALL (BASIC)    STATIC     FUNCTION