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

Question about OnNoData event behavior

edited 10:23AM in General
Hello,

I'd like to better understand when the TppCustomReport.OnNoData event is actually expected to fire, as described in the documentation.

In our tests, the ReportBuilder correctly applies the configured NoDataBehavior, but the OnNoData event itself is never raised.

Our actual goal is to determine programmatically whether a report contains any data (similar to the corresponding property available in Crystal Reports). Is there a supported way to obtain this information, and is the OnNoData event intended for this purpose?

For context: In this case we are using ReportBuilder in an automation scenario. This is not related to the Viewer component or any interactive UI.

Thanks in advance for any clarification.

Best regards,
Markus

Comments

  • Hi Markus,

    The OnNoData event should always fire when the dataset connected to the report returns no data. I tested this with the latest version of ReportBuilder and it is functioning as expected with every NoDataBehavior option.

    If this event is not firing as expected, it is likely caused by a lost reference (loading templates, etc.) or the dataset is in-fact returning data.
    Best Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com
Sign In or Register to comment.