I’m using aspose pdf Generator and I need to write headings in numbering style, but the segment’s text content must be html code, saved in the DB and passed to the method as string.
I know that the html text is supported in Text object by setting the boolean isHtmlTagsupported=true and this feature is also supported by Heading object but when i run my code the result is an error like this
at
..( , Pdf , Heading , ) at ..( , Pdf , , Boolean ) at
..( , Pdf ) at ..( , Pdf ) at Aspose.Pdf.Generator.Pdf.Save(String pdfFile) at TAC.Business.ToolsManager.CreateTestPDF(Boolean isPreview, Int32 testId) in ToolsManager.cs: line 218 at TAC.Business.Tests.PdfUtilityTest.CretePDFTest() in PdfUtilityTest.cs: line 22||
Thanks for using our products.<span style=“font-size:10.0pt;font-family:“Arial”,“sans-serif””>
I
have tested the scenario and I am able to reproduce the same problem. For the
sake of correction, I have logged it in our issue tracking system as <span style=“font-family:“Arial”,“sans-serif””>PDFNEWNET-34045. We
will investigate this issue in details and will keep you updated on the status
of a correction.<span style=“font-size:10.0pt;font-family:“Arial”,“sans-serif””><span style=“font-size:10.0pt;font-family:“Arial”,“sans-serif””>
Thanks for your patience. As stated above, your reported issue has been resolved in Aspose.Pdf for .NET 8.9.0 release. Please note that the issue has been fixed in the new Generator, i.e., the Aspose.Pdf.Document class. Please check the sample code snippet below. Hopefully, it will help you accomplish your task.
Please note that Aspose.Pdf.Generator is obsolete now and we are fixing issues and making enhancements in the new Generator as it follows the DOM approach and is more efficient than the old Generator. Moreover, it can be used to create a new PDF from scratch or manipulate existing PDF documents as well.