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 TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Using Crystal 9 in Delphi 7

Status
Not open for further replies.

wolfiesz

Programmer
Sep 24, 2003
8
GB
Hi there,

I am writing a DB (Paradox) application in Delphi 7 and need to use the Crystal9 crpe32.dll to print my reports. I have serious trouble passing parameters into the report and getting the preview to work.

Can anybody point me to relevant documentation (other than what is supplied with Crystal 9) or information or samples ?

thanks for the help
 
Are you using the CRPE component from Seagate?
I have had luck getting it to work in Delphi 5 and Cr8.5
and would be willing to share code. The trick with the CRPE is to make use of the designtime controls to note the parameters and the order the report says they are vs the order the show in the dialog, those can be different I think. For some reason, all parameters are in correct order except for dateparams --and any after them are numbered as if the dateparam was not there.

The dateparams showed up under paramfield.range[0] (working from memory here)

Scotto the Unwise
Scott_Stanek@arr-maz.com
 
Hi Scotto,

thanks for your advice. In the meanwhile I have played around with this whole thing and after many tests I have come to the conclusiong that there is a serious bug in the Crystal DLL for paradox databases (crxf_p2bbde.dll). I am now using the VCL component recently released by Crystal and this works fine except for reports that have subreports.

The problem here comes with the fact that when you deploy an application to customers, you don't know where it will be installed. The reports written in Crystal however store the exact path to all of the database tables in the reports themselves and they then need to be changed to point to the actual table locations in a deployed situation. This change works (using the VCL) as long as the report has no subreports. As soon as there are subreports, the above mentioned DLL crashes with a GPF. Even Crystal admit (somewhere in the documentation of the VCL) that there some things not quite right with it, but it doesn't seem to bother them enough to fix it.

As there is no workaround for this, I will now change my database and use MS Access.
But thanks for your reply anyway.

regards
Wolfiesz
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top