arrays - Can't create a variable in a while loop in VBScript? -



arrays - Can't create a variable in a while loop in VBScript? -

this code causes error me:

i = 0 set colors = createobject("scripting.dictionary") while < 7 if true dim a(1) a(0) = "go" a(1) = "try" colors.add "space", end if = + 2 loop

i'm not sure why. need similar, initialize dictionary 1 array each key, while loop seems messing up. suggestions? thanks!

once you've dimmed array, cannot dimmed again. can, however, redimed. dim outside loop. if want clear array during each loop, can 1 of following:

redim a(1) ' redim without 'preserve' clear array ' or erase

arrays vbscript

Comments

Popular posts from this blog

php - Android app custom user registration and login with cookie using facebook sdk -

c# - Create a Notification Object (Email or Page) At Run Time -- Dependency Injection or Factory -

Set Up Of Common Name Of SSL Certificate To Protect Plesk Panel -