Home RAP
New Blog Posts: Merging Reports - Part 1 and Part 2

Accessing Dataset Through RAP

edited November 2008 in RAP
What is the syntax I could use to reference the dataset of a data pipeline?

I have a function in Delphi declared something like:

function Calc(var Dataset: TDataset);

I know how to create a passthrough function, but I'm not sure how to use the
function in RAP (the syntax to reference the dataset of the pipeline).

e.g., In a Variable's OnCalc: Value := Calc(MyPipeline); ??

Basically there are a lot of variables from the dataset being used in the
calcuation, and rather than passing them through individually, I want to
pass the entire dataset reference.

Comments

  • edited November 2008
    Hi David,

    My recommendation would be to pass the entire pipeline (Report.DataPipeline)
    to the pass-thru function and access the TDataset from there. This way you
    can typecast the pipeline object as a TppDBPipeline and access its
    DataSource.DataSet property before calling your Calc routine.

    --
    Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com

    Best Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com
  • edited November 2008
    Thanks, Nico. That worked.
This discussion has been closed.