Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > ASP General > Create dynamic array multi-dimension

Reply
Thread Tools

Create dynamic array multi-dimension

 
 
GeckoNewsgroup
Guest
Posts: n/a
 
      02-12-2004
Hi,

When a try this script:

NbrAuteur = 19

Dim arrTestArray()
intSize = 0

1: For x = 0 to (nbrAuteur - 1)
2: ReDim Preserve arrTestArray(intSize,3)
3: arrTestArray(intSize,0) = objRS("prenom")
4: intSize = intSize + 1
5: objRS.movenext
6: Next

I have this msg error:

Microsoft VBScript runtime error '800a0009'
Subscript out of range
Line 2

 
Reply With Quote
 
 
 
 
Ray at
Guest
Posts: n/a
 
      02-12-2004
You can only redimension the last dimension of an array.

Redim preserve anArray(2,4,2,43,VariableNumber)

Ray at work

"GeckoNewsgroup" <(E-Mail Removed)> wrote in message
news:BC512DD7.838%(E-Mail Removed)...
> Hi,
>
> When a try this script:
>
> NbrAuteur = 19
>
> Dim arrTestArray()
> intSize = 0
>
> 1: For x = 0 to (nbrAuteur - 1)
> 2: ReDim Preserve arrTestArray(intSize,3)
> 3: arrTestArray(intSize,0) = objRS("prenom")
> 4: intSize = intSize + 1
> 5: objRS.movenext
> 6: Next
>
> I have this msg error:
>
> Microsoft VBScript runtime error '800a0009'
> Subscript out of range
> Line 2
>



 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Array question - How dynamic is dynamic? Ruby Student Ruby 4 04-09-2009 12:59 PM
create a dynamic array of pointers with initial values of NULL sandy@murdocks.on.ca C++ 23 12-01-2006 11:30 PM
Convert Static Array to Dynamic Array ? raxitsheth@gmail.com C Programming 2 07-14-2005 01:25 AM
Loop to create an array from a dynamic form. Nick ASP General 2 08-26-2004 06:21 PM
Can a static array contain a dynamic array of pointers? Peter B. Steiger C Programming 8 04-26-2004 03:07 AM



Advertisments