[<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
STATIC                   Declare Local Variable(s)

 STATIC varlist

    Declares one or more function or subprogram variables as local and
    memory-based (as opposed to stack-based).

     varlist    A comma-delimited list of valid variable and/or array
                names. Array names must be followed by an integer enclosed
                within parentheses; the integer specifies the number of
                dimensions in the array.

   -----------------------------------------------------------------------

      Notes:    The STATIC statement may be used only within multiline
                function definitions and subprograms.

                Variables used within multiline function definitions are
                global by default. Variables used within subprograms are
                local by default.

                A STATIC variable is a local variable whose value doesn't
                change between subprogram CALLs. Ordinary local variables
                are reinitialized with each CALL. To guarantee that a
                variable's value will not change between CALLs, declare
                the variable STATIC.

                The STATIC statement should not be confused with the
                STATIC attribute of the SUB statement (which indicates
                that a subprogram is nonrecursive) or the $STATIC
                metacommand (which statically allocates memory for
                arrays).

See Also: DEF FN SHARED SUB...END SUB
This page created by ng2html v1.05, the Norton guide to HTML conversion utility. Written by Dave Pearson