Login | Register   
Twitter
RSS Feed
Download our iPhone app
TODAY'S HEADLINES  |   ARTICLE ARCHIVE  |   FORUMS  |   TIP BANK
Browse DevX
Sign up for e-mail newsletters from DevX


Tip of the Day
Language: .NET
Expertise: Beginner
Aug 25, 2009

Using the WebClient Class to Download Data to a File

The following code shows how you can use the WebClient class to obtain data from a URL and save it to a file:

System.Net.WebClient client = new System.Net.WebClient();
byte [] bytedata = client.DownloadData(url);
client.DownloadFile(url,downloadPath);
Srinath MS
 
Comment and Contribute

 

 

 

 

 


(Maximum characters: 1200). You have 1200 characters left.

 

 

Sitemap