victoryhighway2
Programmer
Hello,
I'm working on an application in VB6 that uses Crystal Reports 9 to display reports from user data files created by the application. Specifically, in the application, we're attempting to use a DAO recordset object as the datasource for CrystalReport designer objects created in VB (and mapped in the application's project as Designers). I'm running into a problem where Crystal Reports causes my application to crash (and the VB IDE as well, if I'm running my application under VB) when the following code is executed:
From what I'm understanding (this application was originally written by a developer who is no longer here, and I haven't really done too much with this section of the code), this is what binds the report to the DAO recordset. The recordset itself is based on a SQL query.
The really strange part here is that this only happens randomly. I haven't yet determine a known pattern that will cause this behavior to surface. Most of the time, this works fine, but once in a while it will crash.
Does anyone have any suggestion on how I might go about remedying this problem? I'm not a Crystal Reports expert.
Regards,
Geoffrey
I'm working on an application in VB6 that uses Crystal Reports 9 to display reports from user data files created by the application. Specifically, in the application, we're attempting to use a DAO recordset object as the datasource for CrystalReport designer objects created in VB (and mapped in the application's project as Designers). I'm running into a problem where Crystal Reports causes my application to crash (and the VB IDE as well, if I'm running my application under VB) when the following code is executed:
Code:
rptReport.Database.SetDataSource MyRS, 3, 1
From what I'm understanding (this application was originally written by a developer who is no longer here, and I haven't really done too much with this section of the code), this is what binds the report to the DAO recordset. The recordset itself is based on a SQL query.
The really strange part here is that this only happens randomly. I haven't yet determine a known pattern that will cause this behavior to surface. Most of the time, this works fine, but once in a while it will crash.
Does anyone have any suggestion on how I might go about remedying this problem? I'm not a Crystal Reports expert.
Regards,
Geoffrey