lazyrunner50
Programmer
I am trying to declare an array given the number of results in the resultset, but whenever I put any sort of variable in the declaration of the array, it gives me this error:
I've tried numerous ways to do this, but none of them work:
There are two problems with this one. First - when I printed out result.RecordCount it gave me -1 even though I was able to loop through the recordset and print out all the values. Second, it had the problem with the variable in the declaration
Got the same error as the first method, though when I printed out i, I got 88...
Even tried this, but it didn't work.
Code:
Microsoft VBScript compilation error '800a0402'
Expected integer constant
I've tried numerous ways to do this, but none of them work:
Code:
Dim imageArray(result.RecordCount)
Code:
if not result.EOF then
while not result.EOF
i=i+1
result.movenext()
wend
DIM imageArray(i)
Code:
const someVar=88
DIM imageArray(someVar)