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

Exporting from Delphi5

Status
Not open for further replies.

BrianEllul

Programmer
Jan 22, 2004
9
MT
I'm trying to export a report from Delphi5 using VCL7.5.0.51
However I have problems doing this when the report has got subreports! I don't know if I need to pass the parameters to the subreports as well. Can someone please point me to any links or tell me what properties I'll have to set.

Regards
Brian
 
If the subreport has separate parameters then you need to, if it uses a parameter from the main report to a field in it's datasource (what I sugget doing), then it doesn't need to.

I guess that VCL 7.5.0.51 is some sort of old Crystal version? I've never heard it referred to as VCL.

Here are the Delphi sample applications from BO:


-k
 
Thanks for your answer.

The 7.5.0.51 is the version used with Delphi5. I'm using Crystal 8.5 (which is becoming old now...)

The subreports are linked (and will use) the parameters of the main report. If I preview the report from Crystal, I enter the parameters once for the main report and the report is displayed fine.

When passing the params of the main report through Delphi, it's giving me an access violation on Execute. I temporarily removed the subreports from the main report and all was fine. Therefore I concluded that either I have to pass the params of the subreports manually or else there is a switch which will tell the subreports to get their values from the main report.

This is what I'm doing...
ParamFields.Retrieve;
ParamFields[0].AsNumber:= a;
ParamFields[1].AsNumber:= b;
ParamFields[2].AsNumber:= c;
Execute;

The sample you pointed me to is for Delphi7 and a newer Crystal component which unfortunately I cannot load!

Regards
Brian

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top