Skip to main content Link Menu Expand (external link) Document Search Copy Copied

The BeforeExportReport method is called just before a report is exported to a file or stream.


public bool BeforeExportReport(IReport report, Stream stream)

public bool BeforeExportReport(IReport report, string fileName)


report The report being run.

stream The stream the report is being exported to.

fileName The name of the file the report is being exported to.

Return value

True if the report should be exported, False if not. If you want a message displayed to the user about why it terminated, throw an exception with the appropriate message.


See the example for AfterReportSaved.