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

Free Support Forum - aspose.com

Convert PDF to TIFF doesn't work

I use the latest PDF 4.6.0 for java


I load a simple PDF File and try to convert it as TIFF, I tried differnet ways also with TIFFDevice, but still the same error!

I do this with the attached pdf file

Resolution resolution = new Resolution(300);

TiffSettings tiffSettings = new TiffSettings();
tiffSettings.setCompression(CompressionType.LZW);
tiffSettings.setDepth(ColorDepth.Format8bpp);
tiffSettings.setSkipBlankPages(false);

PdfConverter pdfConverter = new PdfConverter();
pdfConverter.bindPdf("/app/images/tmp/1.pdf");
pdfConverter.setResolution(resolution);

pdfConverter.saveAsTIFF("/app/images/tmp/1.tif", tiffSettings);

and get this error

class com.aspose.ms.System.g: Key cannot be null
Parameter name: key
com.aspose.ms.System.a.j.get_Item(Unknown Source)
com.aspose.pdf.b.b.d$a.d(Unknown Source)
com.aspose.pdf.b.f.b.g(Unknown Source)
com.aspose.pdf.devices.d.a(Unknown Source)
com.aspose.pdf.devices.d.cTs(Unknown Source)
com.aspose.pdf.devices.TiffDevice.processInternal(Unknown Source)
com.aspose.pdf.devices.DocumentDevice.process(Unknown Source)
com.aspose.pdf.facades.PdfConverter.a(Unknown Source)
com.aspose.pdf.facades.PdfConverter.saveAsTIFF(Unknown Source)
it.siag.microfilmmanager.StartImport.(StartImport.java:56)
it.siag.microfilmmanager.MfMImportServiceMain.main(MfMImportServiceMain.java:7)
Exception in thread “main” java.lang.RuntimeException: class com.aspose.ms.System.g: Key cannot be null
Parameter name: key
com.aspose.ms.System.a.j.get_Item(Unknown Source)
com.aspose.pdf.b.b.d$a.d(Unknown Source)
com.aspose.pdf.b.f.b.g(Unknown Source)
com.aspose.pdf.devices.d.a(Unknown Source)
com.aspose.pdf.devices.d.cTs(Unknown Source)
com.aspose.pdf.devices.TiffDevice.processInternal(Unknown Source)
com.aspose.pdf.devices.DocumentDevice.process(Unknown Source)
com.aspose.pdf.facades.PdfConverter.a(Unknown Source)
com.aspose.pdf.facades.PdfConverter.saveAsTIFF(Unknown Source)
it.siag.microfilmmanager.StartImport.(StartImport.java:56)
it.siag.microfilmmanager.MfMImportServiceMain.main(MfMImportServiceMain.java:7)
at com.aspose.pdf.facades.PdfConverter.saveAsTIFF(Unknown Source)
at it.siag.microfilmmanager.StartImport.(StartImport.java:56)
at it.siag.microfilmmanager.MfMImportServiceMain.main(MfMImportServiceMain.java:7)

Hi Michael,


Thanks for contacting support.

I have tested the scenario using Aspose.Pdf for Java 4.6.0 in Eclipse Juno application running over Windows 7 (x64) where I have JDK 1.7 and as per my observations, the PDF file is properly being converted to TIFF format. For your reference, I have also attached the resultant TIFF generated over my end.

Can you please share some details regarding your working environment. We are sorry for this inconvenience.

I am using ubuntu 13.10 x64 with kernel 3.11.0-18

I tested the few lines of code with jvm 1.7.0_51 1.7.0_45 and 1.6.0_45

Do you think the problem is OS relevant?

Michael

Hi Michael,

Thanks for providing additional information. We have tested the scenario over Linux and found that without a valid license
implementation code throws the exception, It works fine with a valid license. Please use a valid license, it will fix the issue.

However, we have logged an investigation ticket PDFNEWJAVA-34099 in our issue tracking system to fix the issue in evaluation mode.

We are sorry for the inconvenience caused.

Best Regards,

Okay thanks, the missing license was the solution! I forgot to load the license in my test client!!!

I also edit my first post and delete some not nice words!
Sorry!

thx for your help!

Michael

Hi Michael,


Thanks for sharing the feedback. We are glad to hear that your problem is resolved by loading a valid license. Nevertheless, we will fix the issue when using API in trial mode and will keep you posted within this forum thread.

Hi,
Is there an update on this front? I am facing the same issue and I think it is because of the missing license. I am using it in trial mode.

Hi RajKiran,


Thanks for you inquiry. Above reported issue has been resolved and fix would be available in upcoming release of Aspose.Pdf for Java 9.0.0. However, for time being you can request a 30 days free temporary license to evaluate our product without any limitation and this exception. It will fix the issue.

Best Regards

The issues you have found earlier (filed as PDFNEWJAVA-34099) have been fixed in this update.


This message was posted using Notification2Forum from Downloads module by Aspose Notifier.