We are adding ids using the InvisibleElementIds property and separating each id with a semi-colon. The Elements are hidden but so is everything else on the page. Even divs without out those element ids
//Code...
StringBuilder sbHtml = new StringBuilder();
//Load string builder from sample html file sent to support
HtmlToPdf.Options.FooterHtmlFormat = "Hello from Footer";
HtmlToPdf.Options.HeaderHtmlFormat = "Hello From Header";
HtmlToPdf.Options.InvisibleElementIds = "header;footer";
PdfDocument doc = new PdfDocument();
HtmlToPdfResult result = HtmlToPdf.ConvertHtml(sbHtml.ToString(), doc);
using (MemoryStream ms = new MemoryStream())
{
doc.Save(ms);
byte[] pdf = ms.ToArray();
File.WriteAllBytes(Environment.CurrentDirectory + "\\testpdf.pdf", pdf);
}
// Notice the body of the PDF is blank and the HTML contains text!
I have sent sample html documents to support. Both the HTML input and the PDF output....
BTW: I am running version 16.2.1.0 on Windows 10 64 bit.
I also noticed this thread where an end user had the same issue and it was supposedly fixed.
https://www.essentialobjects.com/forum/postst9950_EO-PDF-not-supporting-CSS-Flex-property.aspx