|
|
Rank: Newbie Groups: Member
Joined: 5/24/2019 Posts: 7
|
There is a bug in the 26.x.x versions of EO.PDF that is throwing a NullReferenceException when your code has GenerateTags=true and the HTML includes a base64 encoded string. This is not happening if we downgrade back to the latest 25.x.x version. Here is a simple code snippet to reproduce (sorry about the escaping on the html tags):
Code: C#
using var outputStream = new MemoryStream();
var doc1 = new EO.Pdf.PdfDocument();
string html = @"
<html>
<body>
<img src=""data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAIAAACQd1PeAAAAEElEQVR4nGI68pkTEAAA//8ERwHDHBUFcAAAAABJRU5ErkJggg==""
/>
</body>
</html>
";
HtmlToPdf.ConvertHtml(html, doc1, new HtmlToPdfOptions { GenerateTags = true });
// NullReferenceException thrown
doc1.Save(outputStream);
Please confirm the defect and let us know when it can be expected to be fixed.
|
|
Rank: Administration Groups: Administration
Joined: 5/27/2007 Posts: 24,476
|
Thanks for letting us know. We have found the root of the problem. This will be fixed in our next build and we will reply here again when the new build is available.
|
|
Rank: Administration Groups: Administration
Joined: 5/27/2007 Posts: 24,476
|
Hi,
This is just to let you know that we have posted build 26.1.7 that should resolve this problem. Please take a look and let us know how it goes.
Thanks!
|
|