PandaWood / ExceptionReporter.NET

ExceptionReporter is a .NET component that gathers detailed information on an Exception and the application/system running it. It allows the user to copy, save or send a custom-formatted report to the developer
MIT License
51 stars 32 forks source link

Programmatically save report #48

Closed paintballkev812 closed 4 years ago

paintballkev812 commented 4 years ago

Is there a way to programmatically save the report? I have an application would be used offline a majority of the time. My goal is in the event of no internet connection, I would like to save the report locally and on each subsequent startup, I would attempt to resend the bug report.

PandaWood commented 4 years ago

Yes you can programatically save the report - use the ReportGenerator class directly - it's specifically designed for this.

Internally, when the ExceptionReport class sends a report it 1 - Generates a report using the ReportGenerator 2 - Sends it

So, just do (1) and do whatever you want with the report eg condensed code: new ReportGenerator(new ExceptionReportInfo()).Generate()

Write your own code to save the string it returns (local file etc)

paintballkev812 commented 4 years ago

Thanks!