For some reason, you can’t do this in vbscript:
x = 15
Dim demoArray(x)
It throws this error:
Microsoft VBScript compilation (0x800A0402)
Expected integer constant
Instead, you have to do this:
x = 15
Dim demoArray()
ReDim demoArray(x)
Leave a comment