P
pauljturner99
Hi,
I'm trying to pass a parameter from a for loop to the nested while loop
but only the first counter is passed. Here is the code:
dim ctr
redim ctr(5)
ctr(0) = 2
ctr(1) = 4
ctr(2) = 6
ctr(3) = 8
ctr(4) = 10
ctr(5) = 12
dim counter
redim counter(5)
counter(0) = 0
counter(1) = 2
counter(2) = 2
counter(3) = 3
counter(4) = 4
counter(5) = 5
dim ctsum1
redim ctsum1(100)
dim ctsum2
redim ctsum2(100)
dim ctnoOut
redim ctnoOut(100)
dim ct
redim ct(100)
dim f1, f2
Dim re1, re2
dim sum1, sum2
If Not rs.EOF Then
for c = 0 to ubound(counter)
response.write "<tr><td>"
while Not rs.EOF
dim formtext, c1
formtext=(rs.fields.item(ctr(c)).value)
formtext is always 2 but I expect it to be 2, then 4, then 6 etc.. How
do I pass the counter from the for loop to while?
I'm trying to pass a parameter from a for loop to the nested while loop
but only the first counter is passed. Here is the code:
dim ctr
redim ctr(5)
ctr(0) = 2
ctr(1) = 4
ctr(2) = 6
ctr(3) = 8
ctr(4) = 10
ctr(5) = 12
dim counter
redim counter(5)
counter(0) = 0
counter(1) = 2
counter(2) = 2
counter(3) = 3
counter(4) = 4
counter(5) = 5
dim ctsum1
redim ctsum1(100)
dim ctsum2
redim ctsum2(100)
dim ctnoOut
redim ctnoOut(100)
dim ct
redim ct(100)
dim f1, f2
Dim re1, re2
dim sum1, sum2
If Not rs.EOF Then
for c = 0 to ubound(counter)
response.write "<tr><td>"
while Not rs.EOF
dim formtext, c1
formtext=(rs.fields.item(ctr(c)).value)
formtext is always 2 but I expect it to be 2, then 4, then 6 etc.. How
do I pass the counter from the for loop to while?