Report BeforePrint does not fire with dynamic embedded report
I'm creating a composite report by dynamically creating subreports and then
embedding the external reports that I need. However, I'm finding that the
beforeprint events of the external reports aren't firing when the composit
report prints.
It seems to me that they should fire. Otherwise, what would you advise to
get my beforeprint functionality to print in this scenario?
Thank you.
embedding the external reports that I need. However, I'm finding that the
beforeprint events of the external reports aren't firing when the composit
report prints.
It seems to me that they should fire. Otherwise, what would you advise to
get my beforeprint functionality to print in this scenario?
Thank you.
This discussion has been closed.
Comments
Report and ChildReport share a common ancestor - CustomReport. However,
Report adds events for handling the report generation process - one of which
is BeforePrint. When assigning Report to SubReport, it is treated like a
ChildReport and thus events such as BeforePrint are not going to fire.
I would try using the main report's BeforePrint event to manually iterate
over the embedded reports and fire the BeforePrint event for each.
--
Nard Moseley
Digital Metaphors
www.digital-metaphors.com
Best regards,
Nard Moseley
Digital Metaphors
www.digital-metaphors.com