In my situation, I could not use Stream.Copy, as Alex suggested in his answer, because I used the .NET Framework 2.0. Instead, I used only Stream to read binary files, since Streamreader is designed to read only text files:
public static void sampleUpload() {
chridam
source share