Download a file over HTTP into a byte array in C#?

后端 未结 1 570
逝去的感伤
逝去的感伤 2020-12-09 02:13

I\'m trying to read a file that I have a web address for into a byte array. I\'ve been using File.ReadAllBytes to read files locally and I\'ve been unable to f

相关标签:
1条回答
  • 2020-12-09 02:35
    byte[] response = new System.Net.WebClient().DownloadData(url);
    
    0 讨论(0)
提交回复
热议问题