Tag Archives: compare files

Find duplicate files in C#, Part 4 of 4

The last three posts described an application that searches for duplicate files and removes them. The program seems to work fairly well, at least for small test directories. When I tried it on a directory containing around 8,000 files, however, … Continue reading

Posted in algorithms, cryptography, files, system, tools | Tagged , , , , , , , , , , , , , , , , , , | 1 Comment

Find duplicate files in C#, Part 3 of 4

The last two posts described an application that searches for duplicate files and removes them. This post explains how the program removes the files when you click the Delete Selected button. When you click the button, the following code executes. … Continue reading

Posted in algorithms, cryptography, files, system, tools | Tagged , , , , , , , , , , , , , , , , , , | Leave a comment

Find duplicate files in C#, Part 2 of 4

The previous post Find duplicate files in C#, Part 1 of 4 explained how the example uses a LINQ query to select files grouped by hash code. This post explains how the program displays the files’ contents and how the … Continue reading

Posted in algorithms, cryptography, files, system, tools | Tagged , , , , , , , , , , , , , , , , , , | 1 Comment

Find duplicate files in C#, Part 1 of 4

This example lets you find and remove duplicate files. It’s fairly complex, so I’m going to cover it’s more interesting pieces in several posts. I won’t cover some of the less interesting pieces at all. Enter a directory path or … Continue reading

Posted in algorithms, cryptography, files, system, tools | Tagged , , , , , , , , , , , , , , , , , , | 2 Comments

Test different methods that compare directories to see which files they have in common in C#

The example Compare directories to see which files they have in common in C# uses Directory.GetFiles to get the files in two directories. It sorts them and compares the two sorted lists to see which files are in the first … Continue reading

Posted in directories, files | Tagged , , , , , , , , , , , | 1 Comment

Compare directories to see which files they have in common in C#

This example compares directories to see which files they have in common and which files are only in one directory. When you click the Compare button, the following code executes. // Compare the files in each directory. private void btnCompare_Click(object … Continue reading

Posted in directories, files | Tagged , , , , , , , , , , , | 6 Comments