ExamDiff Pro Basic Tutorial #3

:: Tutorials :: ExamDiff Pro :: Home

How to compare binary files

Tutorial Description: This tutorial describes how to compare binary files, and discusses various binary file comparison options.

Video Demonstration


  1. Open ExamDiff Pro and select the Files option in the Compare dialog. Then select two binary files to compare, such as two DLLs.

    ExamDiff Pro main compare dialog

  2. By default, ExamDiff Pro automatically determines whether files are text or binary. The program can automatically recognize text files encoded in ASCII (ANSI), UTF-8, and UTF-16 (both little and big endian) formats (UTF-16 files are detected by byte order marks -- 0xFFFE for little endian and 0xFEFF for big endian). If none of these four encodings are detected, ExamDiff Pro will treat files as binary files. Alternatively, you can select Treat text files as binary in Options | Compare.

    ExamDiff Pro Options dialog, showing the Compare tab

  3. Click Compare. You will get a message similar to this:

    ExamDiff Pro dialog showing that you are comparing two different binary files

  4. Now click Show Details.

    ExamDiff Pro main window, comparing two binary files

  5. Let's try out some binary comparison options. Press Ctrl-J or click on the Options toolbar button ExamDiff Pro Options button to open the Options dialog, and navigate to the Dir Comparison page.

    ExamDiff Pro Options dialog, showing the Binary tab

  6. The first option we will examine is Comparison block size. By default, this is set to 1 byte, which provides the most accurate binary comparison. However, for large file comparison may take such a long time that it makes sense to sacrifice some precision for better performance. Let's change it to 2 bytes:

    ExamDiff Pro main window, comparing two binary files with a block size of two bytes rather than the default size of one byte

    You can see that we get a less-detailed comparison report (e.g. the numbers of differences is now 910 versus 1526 when we used 1-byte blocks) but this result was achieved faster that the first one.

  7. The next options, Number of bytes per line, Byte format, Character set, and External binary editor are self-explanatory and well-documented in the online Help.

  8. One more thing: if, after comparing two text files, you want to see the results of their binary comparison, you can use the Files | Toggle Text/Binary Comparison menu command, or the Toggle Text/Binary Comparison toolbar button ExamDiff Pro Toggle Text/Binary Button. (If you can't find the Toggle Text/Binary Comparison toolbar button on your ExamDiff Pro toolbar, you may have to customize your toolbar, as demonstrated in Basic Tutorial #2, Step 6.)