Function FetchXML(ByVal url As Uri) As XElement
Dim x = WebRequest.Create(url)
Using r = x.GetResponse, rs As New StreamReader(r.GetResponseStream)
Return XElement.Parse(rs.ReadToEnd)
End Using
Call the function with the location of the xml file to get the corresponding XML element, that can be used for needed purpose.
No comments:
Post a Comment