我想报告加密文件的进度,这是我的代码,我该怎么做?
using (FileStream destination = new FileStream(destinationFilename, FileMode.CreateNew, FileAccess.Write, FileShare.None))
using (CryptoStream cryptoStream = new CryptoStream(destination, transform, CryptoStreamMode.Write))
using (FileStream source = new FileStream(sourceFilename, FileMode.Open, FileAccess.Read, FileShare.Read))
{
await source.CopyToAsync(cryptoStream);
}
互换的青春
相关分类