The simply way how to download file is to use WebClient class and its method DownloadFile. This method has two parameters, first is the url of the file you want . Use WebClient class to download an URL to string or file with timeout DownloadFile("consultoresniif.com", @"c:\temp\consultoresniif.com");. 10 ответов. using (var client = new WebClient()) { client. http://csharpexamples .com/download-files-synchronous-asynchronous-url-c/. 7. ответ дан turgay

This is a simple snippet that will allow you to download a file from the internet WebClient webClient; // Our WebClient that will be doing the The variable that will be holding the url address (making sure it starts with http://). DownloadFileAsync(new Uri(url), @"c:\temp\imagepng"); } void You can also download the file synchronously using WebClient. A web URL with a file response string myWebUrlFile "C:/users/desktop/logo. png"; using (var client = new WebClient()) { client.