Click here to Skip to main content
15,897,704 members

Comments by JesperMadsen123 (Top 4 by date)

JesperMadsen123 9-Nov-12 13:30pm View    
Why don't you do a Dictionaty<long,list<string>> then ?? It seems that you have hash collisions or identical files. If you have hash collisions, consider using MD5 or SHA-xxx for the checksum..
JesperMadsen123 4-Nov-12 11:38am View    
Is it possible you read a text file (utf8 or utf16) into a string and calls .Length?
Then the length is not the number of bytes, but the number of chars, and there is a difference.
JesperMadsen123 4-Nov-12 11:37am View    
If you read the entire file into a byte array, or you ask FileInfo for the length, should give the same result. If it doesn't you are probably doing something wrong.
JesperMadsen123 4-Nov-12 10:49am View    
if your code is identical to the posted code, files[] does not contain file contents, but filenames. So files[x].Length should return the length of your filename, not the length of the contents.