Let’s say you have two Excel workbooks, or maybe two versions of the same workbook, that you want to compare. Or maybe you want to find potential problems, like manually-entered (instead of calculated) totals, or broken formulas. If you have Microsoft Office Professional Plus 2013, you can use Microsoft Spreadsheet Compare to run a report on the differences and problems it finds.
Note
Important: Spreadsheet Compare is only available with Office Professional Plus 2013 or Office 365 ProPlus.
To compare two Excel workbooks with Office Professional Plus 2013 you should:
Click Home > Compare Files. The Compare Files dialog box appears.
Click the blue folder icon next to the Compare box to browse to the location of the earlier version of your workbook.
Click the green folder icon next to the To box to browse to the location of the workbook that you want to compare to the earlier version, and then click OK.
In the left pane, choose the options you want to see in the results of the workbook comparison by checking or unchecking the options, such as Formulas, Macros, or Cell Format. Or, just Select All.
Click OK to run the comparison.
How to compare Excel files using GroupDocs.Comparison
Microsoft Office Professional Plus 2013 offers spreadsheet comparisons, but GroupDocs.Comparison provides a possibility to compare worksheet programmatically and you can compare not only two different files, but several at once. Let’s say, there are three or more price list for few years (For example: “2018”, “2019”, “2020”) in the XLSX format or other supported file formats. other and you need to compare their contents. Here is an example of how to compare three price lists using GroupDocs.Comparsion API. Usually you just have to follow these steps:
Instantiate Comparer object with source document path or stream;
Call Add method and specify target document path or stream. Repeat this step for every target document;
Here is the code that is used to compare three price lists.
stringsourceDocumentPath=@"Source Price List.xlsx";// NOTE: Put here actual path to source documentstringtargetOneDocumentPath=@"Target Price List 1.xlsx";// NOTE: Put here actual path to target one documentstringtargetTwoDocumentPath=@"Target Price List 2.xlsx";// NOTE: Put here actual path to target two documentstringoutputPath=@"Result Price List.xlsx";// NOTE: Put here actual path to result documentusing(Comparercomparer=newComparer(sourceDocumentPath)){comparer.Add(targetOneDocumentPath);comparer.Add(targetTwoDocumentPath);comparer.Compare(outputPath);}
As a result, we get a XSLX file where the deleted elements are marked in red, the added – in blue, and the modified – in green
Result Price List
More resources
Advanced Usage Topics
To learn more about document comparison features, please refer to the advanced usage section.
GitHub Examples
You may easily run the code above and see the feature in action in our GitHub examples:
Along with full-featured .NET library we provide simple, but powerful free Apps. You are welcome to compare your DOC or DOCX, XLS or XLSX, PPT or PPTX, PDF, EML, EMLX, MSG and other documents with free to use online GroupDocs Comparison App.
Was this page helpful?
Any additional feedback you'd like to share with us?
Please tell us how we can improve this page.
Thank you for your feedback!
We value your opinion. Your feedback will help us improve our documentation.