CrashReporter.NET icon indicating copy to clipboard operation
CrashReporter.NET copied to clipboard

Can Attach a file to the report?

Open FrancoTampieri opened this issue 7 years ago • 4 comments

Hi I think that will be usefull attach a file to the report sended by mail.

Regards

Francop

FrancoTampieri avatar Feb 12 '18 11:02 FrancoTampieri

@drdran Currently you can't. But it is possible using little modification.

ravibpatel avatar Feb 12 '18 12:02 ravibpatel

For this feature, you might want to consider zipping the attached file (and then support multiple attached files) - otherwise you might have a lot of trouble fiddling with MIME types for each file type.

This might be a hard decision, because If you choose to zip the files into one attachment, you'll probably want to use an existing zip library, but then you might lose an advantage of this library - having no dependencies?

Anyway, I do this in ExceptionReport.NET using DotNetZip - so feel free to see how I did it.

(I support attaching to Simple.MAPI message as well as SMTP - so the code is slightly more complicated)

PandaWood avatar Jun 15 '18 07:06 PandaWood

@PandaWood Thanks for the suggestion. I will definitely look into it. For lightweight zip library, you can check out ZipStorer.

ravibpatel avatar Jun 16 '18 10:06 ravibpatel