sub-reports using End-User & Rap ?
Hi gurus,
I've got end-user reporting solution. I want to create report with
sub-reports using Query Designer custom SQL(not the one generated by Query
Designer) and RAP. Is it possible ? If yes, could you provide some
guideline, escpecially on how to link master-detail pipelines in RAP ?
Cheers,
Dmitry
I've got end-user reporting solution. I want to create report with
sub-reports using Query Designer custom SQL(not the one generated by Query
Designer) and RAP. Is it possible ? If yes, could you provide some
guideline, escpecially on how to link master-detail pipelines in RAP ?
Cheers,
Dmitry
This discussion has been closed.
Comments
My suggestion would be to get this working in Delphi first, then try to move
it to RAP. When would you like to create these subreports? Note that until
recently (RB 9.0x) there were no RAP events available that allow you to link
datasets early enough before the report generation process begins. In RB
9.0x you can try using the BeforePipelineOpen RAP event to link pipelines.
See the following article on linking pipelines in code.
---------------------------------------------------------
Tech Tip: Define Master/Detail DataPipeline Links in Code
---------------------------------------------------------
Defining a Master/Detail relationship for a DataPipeline
requires that the detail pipeline have the
following properties defined:
1. MasterDataPipeline
2. MasterFieldLinks
At Delphi design-time you can use the object inspector
and the DataPipeline's FieldLinks editor to define
the master/detail relationship.
The following example illustrates how to define the
master/detail relationship dynamically at run-time.
var
lFieldLink: TppMasterFieldLink;
begin
{define the master/detail pipeline relationship}
plDetail.MasterDataPipeline := plMaster;
{create a new field link }
lFieldLink := TppMasterFieldLink.Create(nil);
lFieldLink.Parent := plDetail;
{assign the detail field name}
lFieldLink.DetailFieldName := 'CustNo';
{assign the master field name}
lFieldLink.MasterFieldName := 'CustNo';
end;
Note: The DataPipeline linking requires the records in the detail dataset to
be ordered by the linking fields. In the above example, the detail data must
be ordered by CustNo.
--
Regards,
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com