I am creating as HTML page with VbScript.
I have an ADO recordset created and opened with the following lines: The recordset basically returns a count of records existing for a specific field within a Table
I just need one question anwered:
How come in a For loop used later within my procedure, do I get a Type Mismatch error at the following line??
I tried placing a number instead of the Recordset into the Loop and it worked fine. I also tried to place the value of the recordset into a variable, but to no avail (Same type mismatch error). I can't seem to figure out what I am doing wrong.....
Any responses would be greatly appreciated.
Thanks
-vza
I have an ADO recordset created and opened with the following lines: The recordset basically returns a count of records existing for a specific field within a Table
Code:
Dim RsCount
RsCount.Open "Select Count(Field) As FLDCOUNT From Table", Cn
I just need one question anwered:
How come in a For loop used later within my procedure, do I get a Type Mismatch error at the following line??
Code:
For i = 0 To RsCount.Fields("FLDCOUNT").Value - 1
I tried placing a number instead of the Recordset into the Loop and it worked fine. I also tried to place the value of the recordset into a variable, but to no avail (Same type mismatch error). I can't seem to figure out what I am doing wrong.....
Any responses would be greatly appreciated.
Thanks
-vza