Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Assigning ADO recordset to Crystal Reports
Message
 
To
24/07/2001 09:35:34
Peter Walburn
Omega Data Services Ltd
Aberdeen, United Kingdom
General information
Forum:
Visual Basic
Category:
Third party products
Miscellaneous
Thread ID:
00534359
Message ID:
00534492
Views:
12
>Hello,
>
>I am creating and populating an ADO recordset in code and I would then like to poulate a Crystal Report with this recordset. Is there an easy way to do this? I am not using the Data Envirnoment for creating the recordset.

I use CR 7.0 and use this syntax to pass a ADO recordset to it:
        'Open report
        Set objCR = CreateObject("Crystal.CRPE.Application")
        Set gReport = objCR.OpenReport(gReportPath & "rptStockGain.rpt")

        Set rptDB = gReport.Database
        Set rptTables = rptDB.Tables
        Set rptTable = rptTables.Item(1)
        rptTable.SetPrivateData 3, rstReport

        Set rptTable = rptTables.Item(2)
        rptTable.SetPrivateData 3, rstHeader
In which rstReport is my detail and rstHeader is my header fields.
Éric Moreau, MCPD, Visual Developer - Visual Basic MVP
Conseiller Principal / Senior Consultant
Moer inc.
http://www.emoreau.com
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform