set resultFile to choose file with prompt ¬
"Choose the first file to compare, Rudolph"
set posixPathFile_1 to quoted form of POSIX path of resultFile
set resultFile to choose file with prompt ¬
"Choose the second file to compare, Rudolph"
set posixPathFile_2 to quoted form of POSIX path of resultFile
set cmpScript to "cmp " & posixPathFile_1 & " " & posixPathFile_2
try
set compareResult to do shell script cmpScript
on error errMsg number errNum
display dialog errMsg with title "Compare Failed"
return
end try
display dialog "The files are the same"