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

Free Support Forum - aspose.com

Not able to convert ppt from html

I am able to convert html from ppt and then I want to regenerate ppt again from same html …can you help me how to do that?

Even same issue with Aspose.Pdf I am able to convert Pdf to Html but from Html I am not able to get Pdf back…Please can you suggest something in urgency!!


Thanks for contacting support.

In order to convert HTML into PDF using Aspose.PDF for .NET API, please check following code snippet:

Aspose.Pdf.HtmlLoadOptions objLoadOptions = new Aspose.Pdf.HtmlLoadOptions(dataDir);
objLoadOptions.PageInfo.Margin.Bottom = 0;
objLoadOptions.PageInfo.Margin.Top = 0;
objLoadOptions.PageInfo.Margin.Right = 0;
objLoadOptions.PageInfo.Margin.Left = 0;
var htmlContent = File.ReadAllBytes(dataDir + "template.html");
Aspose.Pdf.Document doc = new Aspose.Pdf.Document(dataDir + "template.html", objLoadOptions);
doc.Save(dataDir + "SamplefromHtml.pdf");

In above code snippet, dataDir is location where all resources (images and fonts) are located, which are used in source HTML.

We are checking information related to HTML to PPT Conversion and will get back to you shortly.


I like to inform that Aspose.Slides can save the presentation to HTML
but from HTML to PPT, only basic text related tags can be imported in text frames. Please share feedback with us if there is still an issue.

Thanks for PDF Conversion solution…It worked well…looking forward for any PPT Conversion solution.


I suggest you to please visit this documentation link for your kind reference for possible options concerning to import HTML inside text frame of presentation. This is only possible option using Aspose.Slides when importing HTML to presentation and applies only to HTML text.

Thank you for the link one more issue I am facing:
Conversion of html into doc is best but not allowed to convert html into docx!!


What Aspose API are you using to convert HTML to DOC? Can you please share source code snippet for this conversion? Also, please ZIP and upload your HTML file you are getting this problem with here for testing. We will then investigate the HTML to DOCX issue on our end and provide you more information.

after uploading HTML File I am using following code
DocSaveOptions options = new DocSaveOptions();

        options.DmlEffectsRenderingMode = DmlEffectsRenderingMode.Simplified;
        options.DmlRenderingMode = DmlRenderingMode.Fallback;
        options.UseHighQualityRendering = true;
        options.SaveFormat = Aspose.Words.SaveFormat.Doc;

If I am giving saveformat.DOCX then it is giving error that format is not allowed


Thanks for sharing the detail. You can use .doc or .dot for DocSaveOptions.SaveFormat. To save your document to DOCX, please use OoxmlSaveOptions.SaveFormat.

OoxmlSaveOptions options = new OoxmlSaveOptions();                  
options.SaveFormat = Aspose.Words.SaveFormat.Docx;

Thanks alot @tahir.manzoor, This is working fine for me :slight_smile: