开发者

How do you convert a file in memory to a byte array?

开发者 https://www.devze.com 2023-01-09 06:41 出处:网络
I am using IonicZip to compress video files and stor开发者_高级运维e in a blob field.I have the zip file created just need to convert it to a byte array.How is this done without writing to the harddri

I am using IonicZip to compress video files and stor开发者_高级运维e in a blob field. I have the zip file created just need to convert it to a byte array. How is this done without writing to the harddrive?

Thanks,

Dave


If you can write to a MemoryStream, you can use the "ToArray()" method on the MemoryStream to get a byte array.

0

精彩评论

暂无评论...
验证码 换一张
取 消