Iterating through fields in a recordset

  • Thread starter Thread starter Lance McGonigal
  • Start date Start date
L

Lance McGonigal

Thanks in advance for your help.

Can anyone point me to some code that will let me iterate through the field
of a dynaset using a for each...next loop?

I need this to create a recordset from a crosstab query.

Thanks again.
 
Hi Lance!
Can anyone point me to some code that will let me iterate through the field
of a dynaset using a for each...next loop?

I need this to create a recordset from a crosstab query.

' Assuming DAO, ADO similar:

Dim fld As DAO.Field

For Each fld in MyRst.Fields
Debug.Print fld.Name, fld.Value
Next fld

HTH,
Paul
 
Back
Top