0 votes

Il a un problème d'affichage des images récupérées en utilisant la fonction.
Quick star .NET samples
Il n'est pas possible d'afficher les images source CID.

exemple ::

<img width="177" height="112" style="width:1.8437in;height:1.1666in" id="Image_x0020_4" src="cid:image004.png@01DAC7B5.A4855360">
by

1 Answer

0 votes

You can use IMail.SaveHtmlAs method to save entire message as regular HTML page with all required images and styles into a single folder:

IMail email = ...
email.SaveHtmlAs("c:\\tmp\\email.html");

You can also use IMail.GetBodyAsHtml that returns html body and can inline all cid: images as base64:

string bodyAsHtml = email.GetBodyAsHtml(inlineVisuals: true);

You can find more information on cid: images here:
https://www.limilabs.com/blog/sending-email-with-embedded-image

and here:
https://www.limilabs.com/blog/save-images-embedded-in-html-email-to-disk-using-imap

by (299k points)
...