Compare API shows false changes at the beginning of document

When I use Aspose.Words Compare API to generate redline, it shows changes at the very beginning of the document, even though that part is identical in both files.

Expected: only real differences should be highlighted.
Actual: false positives are marked at the start of the file.

Can you check why this happens and suggest a fix or workaround?

Thanks.

@nborisenko

It sounds like you’re experiencing an issue with the Aspose.Words Compare API, where it highlights changes at the beginning of the document, even though that section is identical in both files. This can occur due to hidden formatting differences or metadata discrepancies between the two documents.

Cause: The discrepancies may stem from hidden formatting marks, extra spaces, line breaks, or differing styles that are not immediately visible.

Solution: Here are several steps to troubleshoot and potentially resolve this issue:

  1. Check for Hidden Formatting: Open both documents in Word and enable formatting marks to check for any hidden elements at the beginning of the document. These can lead to the Compare API detecting changes.

  2. Normalize the Documents: Before comparing, normalize both documents by:

    • Removing unnecessary formatting.
    • Ensuring consistent styles are applied across both documents.
  3. Use the Compare Method with Options: When invoking the Compare method, specify options that may help reduce false positives. For instance, you can ignore certain types of changes or define how to handle formatting.

  4. Review the Result Document: Open the result document and inspect the highlighted changes at the beginning. The visual representation may provide insights into what the API is detecting as a change.

  5. Update Aspose.Words: Ensure you are using the latest version of Aspose.Words, as updates often include bug fixes and enhancements.

Next Steps: If these steps do not resolve the issue, consider sharing the specific documents with Aspose support for a more in-depth analysis.

Please let me know if you need further assistance!

@nborisenko
We have opened the following new ticket(s) in our internal issue tracking system and will deliver their fixes according to the terms mentioned in Free Support Policies.

Issue ID(s): WORDSNET-28577

You can obtain Paid Support Services if you need support on a priority basis, along with the direct access to our Paid Support management team.

The issues you have found earlier (filed as WORDSNET-28577) have been fixed in this Aspose.Words for .NET 25.10 update also available on NuGet.