Click here to Skip to main content
15,868,440 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
Hi, I´m trying to ReDim my array from RecordCount, the problem is my query use PIVOT Table and then RecordSet.RecordCount return -1

I know that I can do two while, once for count and movefirts to works with data
count = 0
While Not Recordset.EOF
count = count + 1
Recordset.movenext
Wend

There is another way to get this information?

Thanks for your time.
Posted

 
Share this answer
 
Thank you very much!!!

This solved my problem

VB
Set objRS = Server.CreateObject("ADODB.Recordset")
objRS.CursorLocation = adUseClient
objRS.Open strSQL, objConn,,adLockReadOnly, adCmdText
 
Share this answer
 
v2

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900