Access Internal Dataset Objects
I have a report with an internal TfrxADOQuery object (on the Data page), and I would like to know its record count before previewing the report. Is this possible?
There is a way to access the report's page objects (data bands, text boxes, etc), but I can't find a way to get to the tables/queries.
I've tried storing the record count in a variable and accessing that, but the query is closed in every event I've tried.
Does anyone have a suggestion for me?
There is a way to access the report's page objects (data bands, text boxes, etc), but I can't find a way to get to the tables/queries.
I've tried storing the record count in a variable and accessing that, but the query is closed in every event I've tried.
Does anyone have a suggestion for me?
Comments
var
ds1:tfrxdataset;
rc: integer
//add code in the empty begin end. block
begin
ds1:= report.getdataset('datasetusernamet');
rc:= ds1.rowcount;
end.