Free Support Forum - groupdocs.com

Null pointer Exception while comparing 2 PDF files


#1

Hi,

Even i am getting same Null pointer Exception while comparing 2 PDF files. My Environment details are as below.

OS : Windows 10 64 bit
JDK : jdk1.8.0_112
IDE : Eclipse neon (4.6.0)


This Topic is created by atirtahir3 using Email to Topic tool.


Compare Pdf From File Without Settings Null Pointer
#2

@ashwin1483,

Can you please confirm if you can compare Word files without any issue? Also, specify API version that you are using.


#3

i have same problem as above, output return null when compare 2 files pdf. i used groupdocs.comparison ver 18.6.3. Comparing with docx, xlsx files without any issue. Hope to help.


#4

@ashwin1483,

We cannot reproduce this issue at our end using version 19.3. See this screenshot - comparison.JPG (202.2 KB) and output - output.pdf (101.4 KB).
Can you please add GroupDocs.Comparison for Java 19.3 JAR file as an external library - external jar.JPG (53.2 KB) and remove its dependency from pom.xml, then share your feedback with us.


#5

@ashwin1483,

Can you please confirm if you can compare attached files successfully?
testtarget.pdf (2.4 KB)
testsource.pdf (2.1 KB)
Make sure you have Calibri and Times New Roman fonts installed in your environment.


#6

@atirtahir3,
output.pdf (123.9 KB)

Sorry for the delayed response, i tested with file provided by you and its working fine attached is the output.pdf file. But i get same execption as below while trying with other pdf’s.

Exception in thread “main” java.lang.NullPointerException
at com.pdfcompare.GroupCompareMainClass.main(GroupCompareMainClass.java:13)


#7

@atirtahir3,

I am using GroupDocs.Comparison for Java 19.3 JAR file as an external library, but still same issue.


#8

@ashwin1483,

It seems that you are evaluating the API in trial mode. Because the output has a evaluation mark and API has limitation in such a case.
But the good thing is you can request a temporary license that is actually a time-restricted full license here.
You have to follow the wizard and on step 5 you can request a temporary license. This document will further help you out - Wizard.zip (152.9 KB).
Secondly, make sure, the font-family that your source and target documents have is installed in your environment.