how to know if a report has subreport and access it
Hi...
Please, forgive my English :-(
I can loop through the objects in a report, but I want to know if the object
is a SubReport...
I have to do this, because I don't know another method:
if pos('SubReport',lObject.Name)<>0 then ......
Then... How can I access the DetailBand property of the SubReport?
I need to change the "BandsPerRecord" property of a SubReport.
Is it possible?
Thanks!
Please, forgive my English :-(
I can loop through the objects in a report, but I want to know if the object
is a SubReport...
I have to do this, because I don't know another method:
if pos('SubReport',lObject.Name)<>0 then ......
Then... How can I access the DetailBand property of the SubReport?
I need to change the "BandsPerRecord" property of a SubReport.
Is it possible?
Thanks!
This discussion has been closed.
Comments
While looping through each report object, you can use the 'is' operator to
check if the current object is a TppSubreport... For instance:
if (lObject is TppSubReport) then
lChildReport := TppSubReport(lObject).Report;
Then you will need to loop through each band of the child report's Band[]
List and do the same thing to find the TppDetailBand.
--
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com