I have a C# program that converts an html document to Word and then to PDF. Before the conversion to PDF I do some removal and insertion of headers using the DocumentBuilder. The html document contains a h1 tag wrapping round the text “A heading line”. In the code before converting to html I attempt to change the h1 setting to Arial 16 by parsing the DOM. In general this works, the pdf displays correctly. However, if I dynamically add a footer to the document, via the builder, that includes page numbering, the heading text displays differently when converted to pdf - Times New Roman 24, I believe.
There is a flag in the code ‘bool setFooterWithNumbering = true;’ that either does or doesnt add the page numbering footer.
I have Aspose.Words 17.9, but I have also tried the latest but it made no difference.
I have attached a simple program with the required documents that produces this issue.
CodeAndDocuments.zip (206.8 KB)