Intercepting Save/Load events for a report in Report Designer
Posted: Sun Mar 22, 2009 8:51 am
Hello,
We've designed our application in a way that a report is stored as a string in a database field, then pulled down to show or edit. I'm trying to find a way to avoid creating a temporary file to edit a report, thus I'm setting the report object in the editor instance and it shows the report just fine. However, when a user clicks Save in the editor menu, the report designer asks for a file name and saves the report on a disk.
Is there a way to intercept the Report Saving event in the editor to suppress the original behavior and instead just take the report instance from the designer, serialize it into and push it back to the database? An example of how to inject my own handler into the Report Saving event would be highly appreciated!
Thank you!
We've designed our application in a way that a report is stored as a string in a database field, then pulled down to show or edit. I'm trying to find a way to avoid creating a temporary file to edit a report, thus I'm setting the report object in the editor instance and it shows the report just fine. However, when a user clicks Save in the editor menu, the report designer asks for a file name and saves the report on a disk.
Is there a way to intercept the Report Saving event in the editor to suppress the original behavior and instead just take the report instance from the designer, serialize it into and push it back to the database? An example of how to inject my own handler into the Report Saving event would be highly appreciated!
Thank you!