private void DownloadButton_Click(object sender, EventArgs e) { using (ChunkingTransferServiceWrapper smartProxy = new ChunkingTransferServiceWrapper()) { FileStream stream = File.OpenWrite("DownloadTest.txt"); smartProxy.Download(new TransferInfo { FilePath = @"C:\test\DownloadTest.txt" }, stream); } }
private void UploadButton_Click(object sender, EventArgs e) { using (ChunkingTransferServiceWrapper smartProxy = new ChunkingTransferServiceWrapper()) { FileStream stream = File.OpenRead("Uploadtest.txt"); smartProxy.Upload(new TransferInfo { FilePath = @"C:\test\uploadtest.txt", SizeBytes = stream.Length }, stream); } }