I use the following code to send Recordset to a CR Main Report:

VB Code:
  1. Option Explicit
  2. Dim Report As New CrystalReport1
  3.  
  4. Private Sub Form_Load()
  5. Dim rs As ADODB.Recordset
  6. Dim strSQL As String
  7.  
  8.    Screen.MousePointer = vbHourglass
  9.  
  10.    strSQL = "SELECT * " & _
  11.                 "FROM Table1 " & _
  12.                 "WHERE Field1 = 'Sales';"
  13.                
  14.    Call GetRS(rs, strSQL)
  15.                    
  16.             With Report
  17.                 .Database.SetDataSource rs
  18.                 .PaperOrientation = crLandscape
  19.                 .PaperSize = crPaperLegal
  20.                 .DiscardSavedData
  21.             End With
  22.  
  23.             With CrystalActiveXReportViewer1
  24.                 .EnableRefreshButton = True
  25.                 .ReportSource = Report
  26.                 .ViewReport
  27.             End With
  28.            
  29.             Screen.MousePointer = vbDefault
  30.    
  31.    
  32. Set Report = Nothing
  33.  
  34. rs.Close
  35. Set rs = Nothing
  36.  
  37. MousePointer = 0
  38.  
  39. End Sub

I have a subreport in this report but I don't want the subreport fetching all of the records in the table and then only displaying the records that I need. I want to know how I can send a recordset to the Subreport?