We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

Can aspose render svg on html to pdf?

Can aspose render svg in an html to pdf?

I am attaching an example.

Hi there,


Thanks for your inquiry. While testing the scenario with latest version of Aspose.Pdf for .NET, We’ve noticed the svg image is rendered as invalid image in resultant PDF and logged the issue as PDFNEWNET-35627 in our issue tracking system for further investigation and resolution. We will notify you via this forum thread as soon as it is resolved.

Sorry for the inconvenience faced.

Best Regards,

Hello Tilal,

I facing similar problem is this issue is fixed yet or not?

I am using following code to generate pdf which contains html in that svg





Page pg1 = pdfDoc.Pages.Add();

String htmlFrag = File.ReadAllText(filepath);



HtmlFragment svgfrag = new HtmlFragment(htmlFrag);







pg1.Paragraphs.Add(svgfrag);



pdfDoc.Save(savepath);



and the refred file(file path) is as attached txt file.

Hi Sameer,


Thanks for your inquriy. I am afraid above logged issue is still not resolved. However, I have created a new issue PDFNET-42062 for your scenario and grouped with above logged issue(PDFNEWNET-35627). We have also requested product team to investigate and share an update as soon as possible. We will keep you updated about the issue resolution progress.

We are sorry for the inconvenience.

Best Regards,

Hello Tilal
Any updates on this?

Hi Sameer,


Thanks for your inquriy. I am afraid the issue is still not resolved. We will notify you as soon as we made some significant progress towards issue resolution.

We are sorry for the inconvenience.

Best Regards,

The issues you have found earlier (filed as PDFNET-35627) have been fixed in Aspose.PDF for .NET 19.7.

The issues you have found earlier (filed as PDFNET-42062) have been fixed in Aspose.PDF for .NET 20.1.