Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Replace 1 of 2 databases with a recordset

Status
Not open for further replies.

jbradley

Programmer
Sep 7, 2001
248
US
I have a CR 8.5 report that I'm viewing from a VB 6 program using the CrystalReport1 OCX control. It pulls data from 2 physical databases, a MS SQL database accessed via ODBC and a local Access database. The SQL database has over 1.3 million records so I would like to replace it with an ADO recordset. I am familiar with using a recordset in a report but I can't seem to get it to work with a recordset and a physical database. Here is my code.
Code:
With CrystalReport1
    .SetTablePrivateData 0, 3, rs
    .WindowTitle = "EpicWare Report"
    .DataFiles(1) = "\\huntjuk2\phonepay\" & strReportDate & ".mdb"
    .ParameterFields(0) = "Archive Date;" & strReportDate & ";TRUE"
    .Destination = crptToWindow
    .Action = 1
End With
What am I missing?
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top