Hi Daniel,
You probably need to work with the query or table that is the report's
data source, not with the report itself. Then one way to proceed is with
something like this air code:
Dim rstR As DAO.Recordset
Dim arRows As Variant
'Open Recordset
Set rstR = CurrentDb.OpenRecordset _
("SELECT ParentID FROM MyQueryOrTable;")
rstR.MoveLast 'do this to ensure correct RecordCount
rstR.MoveFirst
arRows = rstR.GetRows(rstR.RecordCount)
GetRows() provides a two-dimensional array, with the first index
representing fields and the second records. Hence to access the first
(and in this example only) field in the third record you would use
arRows(0, 2)
If you must have a one-dimensional array you will need to iterate
through the recordset using MoveNext, and assigning the field value to
the appropriate array element.
>Hello,
>
[quoted text clipped - 17 lines]
>
>~Daniel
--
John Nurick [Microsoft Access MVP]
Please respond in the newgroup and not by email.