Also to answer this question specifically:-
Quote Originally Posted by pourkascheff View Post
2) Is there another way (similar to checksum) to compare two files are same or not with a simpler built-in functions?
This is actually pretty easy to do. Here's one using MD5 again:-
Code:
    Public Function CompareFiles(ByVal fileName1 As String, ByVal fileName2 As String) As Boolean

        Dim m = MD5.Create()

        Using fs1 = File.OpenRead(fileName1)
            Using fs2 = File.OpenRead(fileName2)
                Return m.ComputeHash(fs1).SequenceEqual(m.ComputeHash(fs2))
            End Using
        End Using

    End Function
This function takes two file names and compare the MD5 hashes of their contents and returns True if the hashes are the same and False is they are not. Example usage:-
Code:
Debug.WriteLine(CompareFiles("d:\0.jpg", "d:\a.jpg"))