Difference between revisions of "$DYNAMIC"

From QB64 Wiki
Jump to navigation Jump to search
Line 17: Line 17:
''See also:''  
''See also:''  
* {{KW|DIM}}
* {{KW|DIM}}, {{KW|Arrays}}

Revision as of 20:07, 17 June 2010

The $DYNAMIC Metacommand allows the creation of dynamic(changeable) array sizes.

== Syntax == REM $DYNAMIC

  • Metacommands require a REM or apostrophy (') before them.
  • Metacommands should be placed at the program start in the main module.
  • Dynamic arrays can be resized using REDIM. The array's type cannot be changed.
  • All data in the array will be lost when redimensioned in QBasic.
  • In QB64, REDIM _PRESERVE can save previous array data.
  • Dynamic arrays can also be resized by the program user's input if desired.

See also:

Keyword Reference - Alphabetical
Keyword Reference - By Usage
Main Wiki Page