Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我正在尝试将我有网址的文件读入字节数组。我一直在File.ReadAllBytes本地读取文件,但我一直无法找出最干净的方法来为网络上的文件执行此操作。
File.ReadAllBytes
我想这只是一小段代码,但我可以通过搜索找到的所有内容都仅适用于本地文件。
byte[] response = new System.Net.WebClient().DownloadData(url);