We have a server running Crystal 8 and are delivering reports through ASP pages. The datasource is an Access database on the same server. I design the reports in Crystal 8.5.
For the reports I've designed so far, I've used a System DSN for the Access database (pointing Crystal at the System DSN under ODBC datasources), and all the reports pull all data into the report and do filtering there. That is getting slow, and I want to try doing some of the filtering based on parameters supplied in the ASP page, then pusing the filtered recordset to Crystal.
I found some examples online of doing this. I have a test report I made based on one table, using a TTX file as the datasource. Then I tried modifying the working ASP code to pass the recordset. But when I try to use SetDataSource, I get this error in the web browser:
Microsoft VBScript runtime error '800a01bd'
Object doesn't support this action
It always references the line with SetDataSource.
I've tried a couple ways:
session("oRpt".Database.SetDataSource rs
session("oRpt".Database.Tables.Item(1).SetDataSource rs
The examples I found for this were all VB examples. Does this not work in an ASP page?
I have tried iterating through the recordset before doing SetDataSource and have verified that the code to build the recordset from the Access table is working ok (i.e., I get the table data displayed before I get the VBScript error above). I just don't know where to look for the problem!
Any help is much appreciated!
-Clint
For the reports I've designed so far, I've used a System DSN for the Access database (pointing Crystal at the System DSN under ODBC datasources), and all the reports pull all data into the report and do filtering there. That is getting slow, and I want to try doing some of the filtering based on parameters supplied in the ASP page, then pusing the filtered recordset to Crystal.
I found some examples online of doing this. I have a test report I made based on one table, using a TTX file as the datasource. Then I tried modifying the working ASP code to pass the recordset. But when I try to use SetDataSource, I get this error in the web browser:
Microsoft VBScript runtime error '800a01bd'
Object doesn't support this action
It always references the line with SetDataSource.
I've tried a couple ways:
session("oRpt".Database.SetDataSource rs
session("oRpt".Database.Tables.Item(1).SetDataSource rs
The examples I found for this were all VB examples. Does this not work in an ASP page?
I have tried iterating through the recordset before doing SetDataSource and have verified that the code to build the recordset from the Access table is working ok (i.e., I get the table data displayed before I get the VBScript error above). I just don't know where to look for the problem!
Any help is much appreciated!
-Clint