Dynamically Redim Array Using Variables

Category:
Lists, Collections and Arrays
Type:
Snippets
Difficulty:
Advanced
Author:
Arkadiy Olovyannikov

Version Compatibility: Visual Basic 6, Visual Basic 5

More information:
VB ReDim statement allow you to use variables to set array bounds. But it doesn't allow to use variables as dimension numbers. In some cases (especially when working with tables) this can be useful.

Instructions: Copy the declarations and code below and paste directly into your VB project.

Declarations:

Code: