N
news
Can someone please tell me where I'm going wrong? I've used getrows
before without any problems, but today, it's just not playing ball (or
more likely I've just forgotten how to do this).
Dim rs As Recordset
Dim arr As Variant
Set rs = DBEngine(0)(0).OpenRecordset("SELECT fdPersonName from
tbPeople")
Debug.Print rs.RecordCount ' Returns 3 as expected
arr = rs.GetRows
Debug.Print UBound(arr, 2) + 1 ' Returns 1 instead of 3
A watch on arr shows an array with bounds of 0,0.
before without any problems, but today, it's just not playing ball (or
more likely I've just forgotten how to do this).
Dim rs As Recordset
Dim arr As Variant
Set rs = DBEngine(0)(0).OpenRecordset("SELECT fdPersonName from
tbPeople")
Debug.Print rs.RecordCount ' Returns 3 as expected
arr = rs.GetRows
Debug.Print UBound(arr, 2) + 1 ' Returns 1 instead of 3
A watch on arr shows an array with bounds of 0,0.