DEV Community

Cover image for In-depth document comparison
Atir Tahir
Atir Tahir

Posted on

3 3

In-depth document comparison

Do you want to compare documents with all small details? Have a look at the following .NET code:

Comparer comparer = new .Comparer(sourcePath);
comparer.Add(targetPath);
CompareOptions compareOptions = new CompareOptions();
StyleSettings changedStyleSettings = new StyleSettings();
changedStyleSettings.HighlightColor = Color.Red;
compareOptions.ChangedItemStyle = changedStyleSettings;
comparer.Compare(@"D:\result.docx", compareOptions);
Enter fullscreen mode Exit fullscreen mode

This is not it. This document comparison API provides a lot of comparison options and support for multiple file formats. The changes detection algorithms used by GroupDocs.Comparison allows to detect changes in different document parts and blocks.
From style changes (e.g. italic, bold, highlighted text) to the item insertion or deletion, everything will be compared.
Have a look at the following screenshot:
Alt Text

Sentry blog image

How I fixed 20 seconds of lag for every user in just 20 minutes.

Our AI agent was running 10-20 seconds slower than it should, impacting both our own developers and our early adopters. See how I used Sentry Profiling to fix it in record time.

Read more

Top comments (0)

AWS Security LIVE!

Join us for AWS Security LIVE!

Discover the future of cloud security. Tune in live for trends, tips, and solutions from AWS and AWS Partners.

Learn More

👋 Kindness is contagious

Please leave a ❤️ or a friendly comment on this post if you found it helpful!

Okay