Ian Journeaux

Ian Journeaux

  • NA
  • 2
  • 4.4k

Converting a relative link to an absolute link

Jan 12 2013 11:15 PM
I am reading a web page with

HttpWebRequest
site = (HttpWebRequest)WebRequest.Create(link);               

HttpWebResponse response = (HttpWebResponse)site.GetResponse();

Stream dataStream = response.GetResponseStream();

StreamReader read = new StreamReader(dataStream);

String data = read.ReadToEnd();


I am parsing the page out to locate some download links but the download links are relative links. I was wondering what the correct method would be to convert it to an absolute link?

Thanks


Answers (1)