Free Support Forum -

Issue with diff output file


When comparing pdf files, both having some difference in the footer section in page number 2. The diff output file generated by the comparison API shows inserted/deleted items in the header of page number 3, not in page no 2. here i am attaching the snapshots.comparisonfile1_snap.png (20.2 KB)
comparisonfile2_snap.png (19.6 KB)
resultDifference_snap.PNG (91.1 KB)



In order to investigate this behavior, we need following details:

  • API platform (.NET or Java)
  • API version that you integrated in the project (e.g. 19.9, 18.10)
  • Sample code
  • Problematic source and target PDF files


Platform: Java
Version: 19.6

Sample Code:

public static void compareFiles(String file1, String file2) throws Exception {
ICompareResult result = null;
try {
License license = new License();
if (License.isValidLicense()) {
Comparer comparison = new Comparer();
ComparisonSettings settings = new ComparisonSettings();
result =, file2, settings);
} catch(com.groupdocs.comparison.internal.c.a.pd.exceptions.IndexOutOfRangeException e) {
finally {
try {
System.out.println(“Files have been successfully compared…”);
} catch(NullPointerException e) {

pdf files are attaching here.source files are named as file1 and file2. and target filecomparedFile.pdf (3.5 MB)
file1.pdf (1.3 MB)
file2.pdf (1.5 MB)
is named as comparedfile.



This issue is reproduced at our end. Hence, it has been logged in our internal issue tracking system with ID: COMPARISONJAVA-762. We are now investigating it. As there is any update, you’ll be notified.


if you can fix this issue, we would consider buying your product as it solves our current business requirement



We are still investigating it. You’ll be notified about the outcomes soon.



Can you please look into this resultant.pdf (3.5 MB) file and let us know if this output is satisfying.