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

Free Support Forum - aspose.com

Licensing problem with aspose total

I have been using aspose to convert Word documents to PDF and that has been working.


I am now converting HTML to PDF and getting this error:
class com.aspose.pdf.internal.ms.System.z9: At most 4 text fragments can be added in evaluation mode.
com.aspose.pdf.TextBuilder.m1(Unknown Source)
com.aspose.pdf.TextBuilder.appendText(Unknown Source)
com.aspose.pdf.z6.m1(Unknown Source)
com.aspose.pdf.internal.foundation.rendering.z17.accept(Unknown Source)
com.aspose.pdf.internal.foundation.rendering.z14.accept(Unknown Source)
com.aspose.pdf.internal.foundation.rendering.z11.accept(Unknown Source)
com.aspose.pdf.internal.foundation.rendering.z14.accept(Unknown Source)
com.aspose.pdf.internal.foundation.rendering.z11.accept(Unknown Source)
com.aspose.pdf.internal.foundation.rendering.z14.accept(Unknown Source)
com.aspose.pdf.internal.foundation.rendering.z11.accept(Unknown Source)
com.aspose.pdf.internal.foundation.rendering.z14.accept(Unknown Source)
com.aspose.pdf.internal.foundation.rendering.z30.accept(Unknown Source)
com.aspose.pdf.z6.m1(Unknown Source)
com.aspose.pdf.ApsUsingConverter.m1(Unknown Source)
com.aspose.pdf.z34.m1(Unknown Source)
com.aspose.pdf.ADocument.m1(Unknown Source)
com.aspose.pdf.ADocument.(Unknown Source)
com.aspose.pdf.Document.(Unknown Source)
com.test.aspose.HtmlToPdfConversion.main(HtmlToPdfConversion.java:48)
at com.aspose.pdf.TextBuilder.m1(Unknown Source)
at com.aspose.pdf.TextBuilder.appendText(Unknown Source)
at com.aspose.pdf.z6.m1(Unknown Source)
at com.aspose.pdf.internal.foundation.rendering.z17.accept(Unknown Source)
at com.aspose.pdf.internal.foundation.rendering.z14.accept(Unknown Source)
at com.aspose.pdf.internal.foundation.rendering.z11.accept(Unknown Source)
at com.aspose.pdf.internal.foundation.rendering.z14.accept(Unknown Source)
at com.aspose.pdf.internal.foundation.rendering.z11.accept(Unknown Source)
at com.aspose.pdf.internal.foundation.rendering.z14.accept(Unknown Source)
at com.aspose.pdf.internal.foundation.rendering.z11.accept(Unknown Source)
at com.aspose.pdf.internal.foundation.rendering.z14.accept(Unknown Source)
at com.aspose.pdf.internal.foundation.rendering.z30.accept(Unknown Source)
at com.aspose.pdf.z6.m1(Unknown Source)
at com.aspose.pdf.ApsUsingConverter.m1(Unknown Source)
at com.aspose.pdf.z34.m1(Unknown Source)
at com.aspose.pdf.ADocument.m1(Unknown Source)
at com.aspose.pdf.ADocument.(Unknown Source)
at com.aspose.pdf.Document.(Unknown Source)
at com.test.aspose.HtmlToPdfConve


The code is:

license.setLicense(“C:/Aspose.Total.Java.lic”);


if( license.getIsLicensed() )
{
// print message that license is applied
System.out.println(“Licensed : Details = “+license.toString());
}
else
{
System.out.println(“Not Licensed”);
}

<td class=“message” style=“word-wrap: break-word; word-break: break-word; padding: 0px 1em 0px 1.25em; font-size: 11px; background-image: url(“qrc:/themes/Default/images/blueBackground.png”); background-attachment: initial; background-origin: initial; background-clip: initial; background-position: 0% 0%; background-repeat: repeat-y;”> String basePath = “C:/Tasks/”;
HtmlLoadOptions htmloptions = new HtmlLoadOptions(basePath);
// Load HTML file
Document doc = new Document(basePath+“Test.html”, htmloptions);
// Save HTML file
doc.save(basePath+”/output.pdf”);
<td class=“messageRight” style=“word-wrap: break-word; word-break: break-word; width: 1px; background-image: url(“qrc:/themes/Default/images/blueBackground.png”); background-attachment: initial; background-origin: initial; background-clip: initial; background-position: 100% 0%; background-repeat: repeat-y;”>

If we reduce the size of the HTML document is converts are expected



Hi there,


Thanks for your inquriy. It seems you are not instantiating license object of Aspose.Pdf for Java. Please note when we use more than one Aspose APIs in our project then we have to instantiate license object of respective API separately. Please check following documentation link, it will help you to resolve the issue.


Please feel free to contact us for any further assistance.

Best Regards,