Send email with HTML body of a report including images

edited 11:10PM in FastReport .NET
How can we send an email including a HTML export of the report in the body of the email? The report contains a logo (image) that should be show up in the body of the email.

We use the following code:
MemoryStream htmlBody = new MemoryStream();
                                            FastReport.Export.Html.HTMLExport htmlExportEmail = new FastReport.Export.Html.HTMLExport();
                                            pdfFile = Path.GetTempPath() + @"\" + dtReport.Rows[0]["Subject"].ToString() + ".Html";
                                            report1.Export(htmlExportEmail, htmlBody);
                                            mail.IsBodyHtml = true;
                                            htmlBody.Seek(0, SeekOrigin.Begin);
                                            StreamReader readerHTML = new StreamReader(htmlBody);
                                            string textHTML = readerHTML.ReadToEnd();
                                            mail.Body = textHTML;

This code results in a HTML body without the image.
We tried also with MHT export. That seems to inlcude the image but in the body it shows a complete syntax of a emai message.

How to solve this problem?

Tia
Hans

Leave a Comment

Rich Text Editor. To edit a paragraph's style, hit tab to get to the paragraph menu. From there you will be able to pick one style. Nothing defaults to paragraph. An inline formatting menu will show up when you select text. Hit tab to get into that menu. Some elements, such as rich link embeds, images, loading indicators, and error messages may get inserted into the editor. You may navigate to these using the arrow keys inside of the editor and delete them with the delete or backspace key.