Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

ADO recordset in ACtiveX script.

Status
Not open for further replies.

MrPeds

Programmer
Jan 7, 2003
219
GB
Hi,

I am using an ActiveX script to iterate through an ADO recordset that I have populated via an Execute SQL task.

Instead of using the MoveFirst, MoveNext methods, is there any safe way of me accessing a specific row in the recordset?

e.g. if I have 10 records in the recordset, and I want to directly access the fifth record, how would i do this? At the moment I am using the AbsolutePosition property but books online seems to suggest this is only possible if its supported by the provider - is there any way that I can do this for all providers?

Thanks,

MrPeds
 
Hi,

I've actually found the answer to my own question, hope it is of use to others.

Basically I used the ADO recordset objects GetRows function to return a 2d array of the records.

When i have the information in an array, I can use standard array notation to index a specific element.

MrPeds
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top