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

Free Support Forum - aspose.com

File to pdf conversion

Hi,

I first evaluated Aspose, and now I have purchased it.
When I downloaded the new jars my code(which worked with evaluation copy of Aspose), stopped working. It seems there is some rearrangement of classes.
Please tell me how to make this piece of code run now -

Document doc;
outputFileName = fileName+".pdf";
try {
doc=new Document(fileName, format , null);

PdfOptions options = new PdfOptions();
options.setHeadingsOutlineLevels(3);
options.setExpandedOutlineLevels(1);

if(LoadFormat.HTML==format)
{
doc.saveToPdf(0, 2, outputFileName, options);
}
else
{
doc.saveToPdf(0, 1, outputFileName, options);
}


} catch (Exception e) {
LOG.error(e);
return false;
}

Thanks.

Hi<?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" />

Thanks for your request. I cannot reproduce the problem on my side. Your code works fine. Could you please provide more information about the problem?

Best regards,