Array Subscript out of range: 
Author Message
 Array Subscript out of range:



Sun, 30 May 2004 05:14:26 GMT  
 Array Subscript out of range:
I think your message was out of range. Couldn't even see it.  :)




Sun, 30 May 2004 05:34:59 GMT  
 Array Subscript out of range:
Sorry :)
This is the problem i am running Win 2kS IIS5 asp3 i have a 3d array that get build dynamic when i try to find a key i got arra subscript out range see code

intNewBound = UBound(aArray, 2)
i = 0

if VarType(i) <= intNewBound Then

 strC0 = aArray(C0, i)
 strC1 = aArray(C1, i)
 strC2 = aArray(C2, i)
 more code

i = CInt(i) + 1
End If
 what happens is that "i" will be greater than intNewBound and will go inside the if(5 <= 4) which is not correct and the index will be out of range I try to CInt intNewBound flash the value of intNewBound and TypeVar to find the type of data everything looks correct any help.
Thank You

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!



Sun, 30 May 2004 11:22:45 GMT  
 Array Subscript out of range:
???

For any value of i from -32767 to +32767, VarType(i) will return 2 to indicate that i contains an integer.

You need to post a better description of what you are trying to accomplish.  The example you posted doesn't make much sense.  

--
Michael Harris
Microsoft.MVP.Scripting

Sorry :)
This is the problem i am running Win 2kS IIS5 asp3 i have a 3d array that get build dynamic when i try to find a key i got arra subscript out range see code

intNewBound = UBound(aArray, 2)
i = 0

if VarType(i) <= intNewBound Then

 strC0 = aArray(C0, i)
 strC1 = aArray(C1, i)
 strC2 = aArray(C2, i)
 more code

i = CInt(i) + 1
End If
 what happens is that "i" will be greater than intNewBound and will go inside the if(5 <= 4) which is not correct and the index will be out of range I try to CInt intNewBound flash the value of intNewBound and TypeVar to find the type of data everything looks correct any help.
Thank You

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!



Sun, 30 May 2004 12:02:47 GMT  
 
 [ 4 post ] 

 Relevant Pages 

1. array subscript out of range

2. Passing Arrays to Functions - Subscript Out of Range Problem

3. HELP! Subscript Out Of Range error referencing array

4. Defining an array and getting Subscript Out of Range Error

5. subscript out of range? (floating array problem)

6. Arrays Problem SUBSCRIPT OUT OF RANGE

7. Subscript out of range Error when using Arrays

8. "subscript out of range" - Excel

9. Subscript Out Of Range Error

10. subscript out of range

11. Subscript out of range error

12. Subscript Out Of Range

 

 
Powered by phpBB® Forum Software