Free Support Forum -

HTML files converted to PDF with whole URL from Hyperlink using Aspose.HTML for .NET

Hi ,
When i am using ASPOSE.HTML to convert HTML files to PDF the files get converted properly but with the url getting printed along with the hyperlink and brackets.

image.png (20.7 KB)

Code snippet:

#region Aspose Code
                    Aspose.Html.HTMLDocument htmlDocument = new Aspose.Html.HTMLDocument(htmlfile);
                    Aspose.Html.Saving.PdfSaveOptions options = new Aspose.Html.Saving.PdfSaveOptions { JpegQuality = 100 };
                    OutputPdf = Path.Combine(txtOutpath.Text.Trim(), Path.ChangeExtension(finfo.Name, ".pdf"));
                    Converter.ConvertHTML(htmlDocument, options, OutputPdf);

Please suggest some option or a way to remove this.


Can you please share source HTML file with us so that we may further investigate to help you out.

Hi Adnan,

Here is the sample that you asked for. (1.2 KB)


I have worked with source file shared by you using Aspose.HTML 20.1 and unable to observe the issue. I have also shared my generated result with you for your kind reference. Can you please share generated result with me along with comparison screenshot as well. Also please share version details as well.HTMLtoPDF_Output.pdf (82.8 KB)