none
save html file

    Question

  • Hi

    I have 10 diffrent url like shown below , i want to download it in some folder and i want to fetch the data i am working in c#,  waiting for the reply

    files are in html format

    http://www.linkedin.com/pub/john-smart/4/14/5AA

    http://www.linkedin.com/pub/jennie-p/3/BA7/ABA

    http://www.linkedin.com/pub/debra-lindsey/3/BA6/8A2

    http://www.linkedin.com/pub/dick-stowell/3/BA7/30

    http://www.linkedin.com/pub/charles-feazell/3/BA7/350

    http://www.linkedin.com/pub/marci-asckewitz/3/BA7/541

     


    salman

    Monday, November 28, 2011 10:01 AM

Answers

All replies

  • Monday, November 28, 2011 10:51 AM
  • Thnaks Prahalnathan for replying below is the code for achieving the above req

     

    System.Net.WebClient webClient = new WebClient();

                    webClient.DownloadFile("http://www.linkedin.com/pub/marci-asckewitz/3/BA7/541", @"D:\Test\localfile1.html");

                    webClient.DownloadFile("http://www.linkedin.com/pub/charles-feazell/3/BA7/350", @"D:\Test\localfile2.html");

                    webClient.DownloadFile("http://www.linkedin.com/pub/dick-stowell/3/BA7/30", @"D:\Test\localfile3.html"); 


    salman
    • Proposed as answer by Prahalnathan Monday, November 28, 2011 11:39 AM
    Monday, November 28, 2011 11:37 AM
  • Hi mohammad,

    I'm glad to hear that you got it working. If you have any difficulty in future programming, we welcome you to post here again.


    Bob Shen [MSFT]
    MSDN Community Support | Feedback to us
    Wednesday, December 07, 2011 3:23 AM