p2p.wrox.com Forums

Need to download code?

View our list of code downloads.


  Return to Index  

proasp_codeclinic thread: Array


Message #1 by "Dyrnes, Jan Arve" <jan.arve.dyrnes@f...> on Wed, 6 Sep 2000 14:39:34 +0200
VBscript, right?

First: dim a()		''to define an array (size unspecified)

Later in code:  redim a(nn)	''where nn is variable =3D upper bound of 
the
array

Use:  redim Preserve a(nn+1) to increase size of array while preserving
current contents of dynamic array.  If you don't say Preserve, all 
prior
contents are lost.

Good luck!

-----Original Message-----
From: Dyrnes, Jan Arve [mailto:jan.arve.dyrnes@f...]
Sent: Wednesday, September 06, 2000 5:40 AM
To: Code Clinic
Subject: [proasp_codeclinic] Array


Hi

I'm working on a stupid array thing and just can't remeber the syntax.
Please do help..

Here's some of the some code:

Dim A

a =3D Request.QueryString.Count

DIM Array1(a)

This isn't alowed, the following error is beeing desplayed:
Expected integer constant
/sp=F8rreunders=F8kelse/database_insert.asp, line 13
DIM SvarArray(a)

I no this is a silly quistion but i'm traing anny way, sorry about my
english but as a Norvegian I'm not that good spelling the words right.

Thank's
Jan Arve Dyrnes



  Return to Index