VB Code:
  1. Dim db As ADODB.Connection
  2. Dim rs As ADODB.Recordset
  3. Dim dteFormat As StdDataFormat
  4. Dim strSQL As String
  5.  
  6. Set db = New ADODB.Connection
  7.  
  8. 'A hierarchical recordset requires the MSDataShape provider.
  9. [B]db.Open "provider=msdatashape;data provider=sqloledb;data source=handel;" _
  10.       & "initial catalog=northwind;integrated security=sspi"[/B]
  11. Set rs = New ADODB.Recordset
  12.  
  13. strSQL = "Shape {Select CustomerId, CompanyName From Customers} " _
  14.     & "Append ({Select CustomerId, OrderId, OrderDate From Orders} As Orders " _
  15.     & "Relate CustomerId To CustomerId)"
  16.  
  17. rs.Open strSQL, db, adOpenStatic, adLockReadOnly
  18. Set rs.ActiveConnection = Nothing
  19.  
  20. 'Group header section - contains 1 unbound rptTextBox control
  21. DataReport1.Sections("Section6").Controls(1).DataField = "CompanyName"
  22.  
  23. 'details section - contains 2 unbound rptTextBox control
  24. With DataReport1.Sections("Section1").Controls
  25.     .Item(1).DataMember = "Orders" 'indicate the field is from the Child recordset
  26.     .Item(1).DataField = "OrderId"
  27.    
  28.     Set dteFormat = New StdDataFormat
  29.     dteFormat.Type = fmtCustom
  30.     dteFormat.Format = "dd-MMM-yyyy"
  31.  
  32.     .Item(2).DataMember = "Orders"
  33.     .Item(2).DataField = "OrderDate"
  34.     Set .Item(2).DataFormat = dteFormat
  35. End With
  36.  
  37. 'Group Footer section - contains 1 unbound rptFunction control
  38. 'indicates the total # of orders per customer group
  39. With DataReport1.Sections("Section7").Controls
  40.     .Item(1).DataMember = "Orders"
  41.     .Item(1).DataField = "OrderId"
  42.     .Item(1).FunctionType = rptFuncRCnt
  43. End With
  44.  
  45. DataReport1.Sections("Section7").ForcePageBreak = rptPageBreakAfter
  46.  
  47. Set DataReport1.DataSource = rs
  48. DataReport1.Show
  49.  
  50. Set dteFormat = Nothing
  51. Set rs = Nothing
  52. db.Close
  53. Set db = Nothing

I found this here in Reporting... forum

I want to know what is the proper way to connect a .MDB or MS Access 2000 file